ipv6_entry_test - openconfig/featureprofiles GitHub Wiki
Validate IPv6 route entry support in gRIBI, specifically focusing on IPv6 prefixes with prefix length strictly greater than 64 bits (such as /65, /96, /126, /127, and /128). This verifies that the device agent (DA) and underlying switch ASIC (e.g. TCAM / ALPM paired memory tables) correctly program and forward traffic for longer IPv6 prefixes without prefix bitmask truncation, incorrect table allocation, or route lookup failures.
- Connect ATE port-1 to DUT port-1, ATE port-2 to DUT port-2, and ATE port-3 to DUT port-3.
- Establish gRIBI client connection with DUT, negotiating
RIB_AND_FIB_ACKas the requestedack_typeand persistence modePRESERVE. Make it become leader. Flush all entries after each case.
- Using gRIBI Modify RPC install the following IPv6Entry sets, and validate the specified behaviours:
-
Single next-hop with prefix length > 64:
- Install
2001:db8:100::/65to NextHopGroup containing one NextHop specified to ATE port-2. - Forward packets from ATE port-1 destined to
2001:db8:100::/65and verify 100% traffic arrives on ATE port-2 with 0% traffic loss.
- Install
-
Multiple next-hops (ECMP) with prefix length > 64:
- Install
2001:db8:100::/65to NextHopGroup containing two NextHop entries specified to ATE ports 2 and 3. - Forward packets destined to
2001:db8:100::/65and verify traffic is balanced across ATE ports 2 and 3.
- Install
-
Multiple next-hops with MAC override with prefix length > 64:
- Install
2001:db8:100::/65to NextHopGroup containing NextHops with destination MAC override, and verify traffic forwards successfully without packet loss.
- Install
-
Non-existent next-hop with prefix length > 64:
- Send Modify() installing
2001:db8:100::/65referencing next-hops that do not exist. Validate that FAILED error is received and traffic is dropped.
- Send Modify() installing
-
Downed next-hop interface with prefix length > 64:
- Install
2001:db8:100::/65to NextHopGroup with NextHops on port 2 and port 3. - Set link state down on port 2.
- Forward packets and verify 100% traffic reroutes to port 3 without packet loss.
- Install
-
Longest Prefix Match (LPM) Discrimination (/64 vs /65):
- Install
2001:db8:200::/64-> NextHop(ATE port-2). - Install
2001:db8:200::/65-> NextHop(ATE port-3). - Send Flow 1 destined to
2001:db8:200::1/128(matches/64and/65) -> verify it arrives on ATE port-3 due to LPM. - Send Flow 2 destined to
2001:db8:200:0:8000::1/128(matches/64but has bit 65 = 1, so outside/65) -> verify it arrives on ATE port-2.
- Install
-
Boundary Prefix Length Sweep (/65, /96, /126, /127, /128):
- Install and verify forwarding for boundary prefixes:
-
/65(2001:db8:101::/65) -
/96(2001:db8:102::/96) -
/126(2001:db8:103::/126) -
/127(2001:db8:104::/127) -
/128(2001:db8:105::1/128)
-
- Verify zero packet loss for each prefix length to ensure hardware table allocation succeeds across all bit boundaries.
- Install and verify forwarding for boundary prefixes:
-
Route Deletion and Flush:
- Verify route removal and FlushAll cleanly clears all IPv6 entries from FIB.
-
Single next-hop with prefix length > 64:
N/A
N/A
- gRIBI
- Modify()
- ModifyRequest:
- AFTOperation:
- id
- network_instance
- op
- Ipv6
- Ipv6EntryKey: prefix
- Ipv6Entry: next_hop_group
- next_hop_group
- NextHopGroupKey: id
- NextHopGroup: next_hop
- next_hop
- NextHopKey: id
- NextHop:
- ip_address
- AFTOperation:
- ModifyResponse:
- AFTResult:
- id
- status
- AFTResult:
- ModifyRequest:
- Modify()
paths:
/interfaces/interface/config/description:
/interfaces/interface/config/enabled:
/interfaces/interface/config/name:
/interfaces/interface/config/type:
/interfaces/interface/ethernet/config/port-speed:
/interfaces/interface/subinterfaces/subinterface/ipv4/addresses/address/config/ip:
/interfaces/interface/subinterfaces/subinterface/ipv4/addresses/address/config/prefix-length:
/interfaces/interface/subinterfaces/subinterface/ipv4/neighbors/neighbor/config/link-layer-address:
/interfaces/interface/subinterfaces/subinterface/ipv6/addresses/address/config/ip:
/interfaces/interface/subinterfaces/subinterface/ipv6/addresses/address/config/prefix-length:
/interfaces/interface/subinterfaces/subinterface/ipv6/neighbors/neighbor/config/link-layer-address:
/interfaces/interface/subinterfaces/subinterface/ipv6/config/enabled:
/network-instances/network-instance/interfaces/interface/config/id:
/network-instances/network-instance/interfaces/interface/config/interface:
/network-instances/network-instance/interfaces/interface/config/subinterface:
/network-instances/network-instance/protocols/protocol/config/identifier:
/network-instances/network-instance/protocols/protocol/config/name:
/network-instances/network-instance/protocols/protocol/static-routes/static/config/prefix:
/network-instances/network-instance/protocols/protocol/static-routes/static/next-hops/next-hop/config/index:
/network-instances/network-instance/protocols/protocol/static-routes/static/next-hops/next-hop/interface-ref/config/interface:
rpcs:
gnmi:
gNMI.Get:
gNMI.Set:
gNMI.Subscribe:
gribi:
gRIBI.Flush:
gRIBI.Get:
gRIBI.Modify:{
"network-instances": {
"network-instance": [
{
"name": "DEFAULT",
"config": {
"name": "DEFAULT"
}
}
]
}
}