-
Notifications
You must be signed in to change notification settings - Fork 5
MRIB: Multicast RIB implementation #576
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
5e30869 to
60d37bc
Compare
71919aa to
512b04d
Compare
Implements the Multicast Routing Information Base for multicast
support. The MRIB follows a two-table architecture (mrib_in → mrib_loc)
with RPF verification against the unicast RIB when sources are provided.
This PR includes:
- `rdb/src/db.rs`: modifications to accomodate MRIB implementation and
persistence
- `rdb/src/mrib/mod.rs`: the core MRIB implementation with route storage and
change notifications
- `rdb/src/mrib/rpf.rs`: RPF verification using poptrie for O(1) LPM lookups,
with rate-limited rebuilds triggered on unicast RIB changes
- `rdb/src/types.rs`: Validated multicast address types with input validation
- `mg-api/src/lib.rs`: API v3 (VERSION_MULTICAST_SUPPORT) with new endpoints
- `mgd/src/mrib_admin.rs`: HTTP handlers bridging API to MRIB
- `mgadm/src/mrib.rs`: CLI for MRIB inspection and configuration
Note that Omicron is source of truth multicast overlay/underlay
groups/addresses.
512b04d to
327a609
Compare
| use omicron_common::address::{ | ||
| IPV4_ADMIN_SCOPED_MULTICAST_SUBNET, IPV4_GLOP_MULTICAST_SUBNET, | ||
| IPV4_LINK_LOCAL_MULTICAST_SUBNET, IPV4_MULTICAST_RANGE, | ||
| IPV4_SPECIFIC_RESERVED_MULTICAST_ADDRS, IPV4_SSM_SUBNET, | ||
| IPV6_ADMIN_SCOPED_MULTICAST_PREFIX, IPV6_INTERFACE_LOCAL_MULTICAST_SUBNET, | ||
| IPV6_LINK_LOCAL_MULTICAST_SUBNET, IPV6_MULTICAST_RANGE, | ||
| IPV6_RESERVED_SCOPE_MULTICAST_SUBNET, IPV6_SSM_SUBNET, | ||
| }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there an omicron branch that goes alongside this?
The main reason I ask is because I want to make sure everything builds okay.
In my IPv6 work I noticed that there were some build failures due to circular dependencies in the rdb crate, so to break the dependency loop I ended up moving a bunch of the types that omicron imports into a new rdb_types crate. To get my omicron branch (not merged yet) to build, I had to update it to depend on rdb_types instead of rdb.
I'm not sure if omicron would require the same thing for your changes, but I want to make sure this isn't a problem here too.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep. I included that in Cargo.toml:
oximeter = { git = "https://github.com/oxidecomputer/omicron", branch = "zl/mcast-implicit-lifecycle" }
oximeter-producer = { git = "https://github.com/oxidecomputer/omicron", branch = "zl/mcast-implicit-lifecycle" }
oxnet = { version = "0.1.4", default-features = false, features = ["schemars", "serde"] }
omicron-common = { git = "https://github.com/oxidecomputer/omicron", branch = "zl/mcast-implicit-lifecycle" }There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But, yeah, I'll check on the circular dependency.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems like it'll work out, but I'll double-check this once we get the updates back in to Omicron.
|
Things are looking good overall. So far, I've been able to review everything except for |
MRIB: API naming consistency and doc and validation fixes Address PR #576 review feedback: rename MRIB functions to match unicast patterns (get_mrib_*, read/update_mrib_*), fix stale doc comments, make API more flexible, and minor cleanups.
Implements the Multicast Routing Information Base (MRIB) for multicast support. The MRIB follows a two-table architecture (
mrib_in→mrib_loc) with RPF verification against the unicast RIB when sources are provided.This PR includes:
rdb/src/db.rs: modifications to accomodate MRIB implementation and persistencerdb/src/mrib/mod.rs: the core MRIB implementation with route storage and change notificationsrdb/src/mrib/rpf.rs: RPF verification using poptrie for O(1) LPM lookups, with rate-limited rebuilds triggered on unicast RIB changesrdb/src/types.rs: Validated multicast address types with input validationmg-api/src/lib.rs: API v3 (VERSION_MULTICAST_SUPPORT) with new endpointsmgd/src/mrib_admin.rs: HTTP handlers bridging API to MRIBmgadm/src/mrib.rs: CLI for MRIB inspection and configurationNote that Omicron is source of truth multicast overlay/underlay groups/addresses.