Fill in IPv6 and BGP unnumbered support in oxstats
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 38/100
- issue の種類
- 機能追加
- 明瞭さ
- おおむね明確
- 活発さ
- 停滞
- 技術スタック
- rust
調査の方向性
oxstats.rs を読み、bgp_stats()、static_stats()、rib_stats() と、issue で説明されている BgpSession、StaticRoutingConfig、SwitchRib の各 target に重点を置いてください。PeerId と AddressFamily の値がどのようにメトリクスに到達するかを追跡し、そのうえで番号のない peer と IPv4/IPv6 の次元をどのように表現すべきかを判断してください。BGP、static-route、RIB の統計が、既存のメトリクスを失うことなく、不足している peer と address-family の区別を公開できれば完了です。
索引モデルが issue の本文から書いたものです。
説明
Oxstats currently has no awareness of the PeerId enum (allowing IP and interface based peers to coexist) and only queries the IPv4 Unicast address family. This needs to be updated for full (and correct) stats exposure into oxstats.
Asking Claude to summarize the gaps in oxstats for ipv6 and bgp unnumbered functionality:
Oxstats IPv6 / BGP Unnumbered Gaps
Gap 1: BGP unnumbered sessions are completely excluded from metrics
oxstats.rs:287-293 — The bgp_stats() method explicitly skips unnumbered sessions:
if let PeerId::Ip(addr) = key {
session_counters.insert(*addr, session.counters.clone());
session_count += 1;
}
PeerId::Interface(String) sessions (unnumbered peers discovered via NDP on an interface) are silently dropped. All 29 BGP counters (keepalives, opens, updates, prefixes, transitions, errors, etc.) are missing for unnumbered peers.
Root cause: The BgpSession oximeter target struct has a peer field that's typed as an IpAddr. An interface name like "eth0" can't be represented. The timeseries schema itself would need updating to support a string-based peer identifier, or a parallel timeseries for unnumbered sessions.
Gap 2: Static route stats only report IPv4
oxstats.rs:689-722 — The static_stats() method only queries IPv4:
self.db.get_static_count(AddressFamily::Ipv4)
// ...
self.db.get_static_nexthop_count(AddressFamily::Ipv4)
IPv6 static routes (AddressFamily::Ipv6) are completely ignored. The StaticRoutingConfig target doesn't differentiate by address family either, so even if you added IPv6 counts, there's no way to distinguish them in the current schema — the counts would need separate metrics or an address-family field on the target.
Gap 3: RIB stats are aggregated without AF breakdown
oxstats.rs:727-744 — The rib_stats() method calls full_rib(None), which merges IPv4 and IPv6 RIBs into a single ActiveRoutes gauge. There's no way to see IPv4 vs IPv6 active route counts independently. The SwitchRib target has no address-family dimension.
Summary
┌───────────────────────┬────────────────────────────┬──────────────────────────────────┬──────────────┐
│ Area │ IPv4 │ IPv6 │ Unnumbered │
├───────────────────────┼────────────────────────────┼──────────────────────────────────┼──────────────┤
│ BGP session counters │ Reported │ Reported (if numbered IPv6 peer) │ Not reported │
├───────────────────────┼────────────────────────────┼──────────────────────────────────┼──────────────┤
│ Static route counts │ Reported │ Not reported │ N/A │
├───────────────────────┼────────────────────────────┼──────────────────────────────────┼──────────────┤
│ Static nexthop counts │ Reported │ Not reported │ N/A │
├───────────────────────┼────────────────────────────┼──────────────────────────────────┼──────────────┤
│ RIB active routes │ Merged into single count │ Merged into single count │ N/A │
├───────────────────────┼────────────────────────────┼──────────────────────────────────┼──────────────┤
│ BFD │ Reported (keyed by IpAddr) │ Reported (keyed by IpAddr) │ N/A │
├───────────────────────┼────────────────────────────┼──────────────────────────────────┼──────────────┤
│ mg-lower │ Reported (no AF dimension) │ Same │ N/A │
└───────────────────────┴────────────────────────────┴──────────────────────────────────┴──────────────┘
The most significant gap is #1 — unnumbered BGP sessions have zero observability through oximeter. This is a blind spot for any deployment using BGP unnumbered, since you can't see session state transitions, keepalive health, or prefix exchange rates for those peers.
- 主要言語
- Rust
- スター
- 100
- フォーク
- 8
- 平均マージ
- 2日 1時間
- マージ済み PR(30日)
- 18
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
oxidecomputer/maghemite のほかの issue
-
ICMPv6 Router Solicitations are generated with invalid checksums対応中かも @taspelund が 154 日前に担当しました。 オープンBug mgd ndp rust
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
oxidecomputer/maghemite#802 ·
メンテナーはふだん 1 日以内に返信
-
ddm
難易度 5/5 1週間以上 初心者へのやさしさ 12/100
oxidecomputer/maghemite#1039 ·
メンテナーはふだん 1 日以内に返信
-
ddm want
難易度 3/5 1〜2日 初心者へのやさしさ 35/100
oxidecomputer/maghemite#1033 ·
メンテナーはふだん 1 日以内に返信
-
Bug ddm rust
難易度 3/5 1〜2日 初心者へのやさしさ 78/100
oxidecomputer/maghemite#997 ·
メンテナーはふだん 1 日以内に返信
-
🤖 ddm: a withdraw removes a route that a second source still gives対応中かも @taspelund が 19 日前に担当しました。 オープンBug ddm rust
難易度 4/5 3〜5日 初心者へのやさしさ 25/100
oxidecomputer/maghemite#996 ·
メンテナーはふだん 1 日以内に返信
oxidecomputer/maghemite の issue をすべて見る
似ている issue
-
[Bug]: Add Data's question says "Link to the file" for a GeoPackage where small tables are copiedオープンunconfirmed possible issue
難易度 2/5 1〜3時間 初心者へのやさしさ 64/100
メンテナーはふだん 1 日以内に返信
-
documentation
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
jerney-nexus/epikrise#364 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
Yeachan-Heo/gajae-code#8058 ·
メンテナーはふだん 1 日以内に返信
-
bug daemon
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
メンテナーはふだん 1 日以内に返信
-
good first issue
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
メンテナーはふだん 1 日以内に返信