Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Multicast RIB Component

The multicast RIB (mRIB) holds the multicast forwarding entries flockd programs into the dataplane. Each entry is keyed by a source and a group -- an (S,G) -- and carries the incoming interface packets for that pair must arrive on, and the set of outgoing interfaces they are replicated to. PIM is the only protocol that writes it, so every entry reports an origin of Pim.

The mRIB holds a table per VRF per address family, and it holds only entries that are ready to forward: PIM adds an (S,G) once its RPF has resolved and its outgoing interface list is non-empty, and withdraws it when either stops being true. So flockc pim vrf <vrf-name> rib shows entries the mRIB does not -- an (S,G) still waiting on RPF resolution is real PIM state with no forwarding entry behind it. When an (S,G) you expect is missing here, that command says why.

Operational State

Stats

flock@r1:~$ flockc mrib vrf default stats
{"v4":{"entry_count":1,"protocol_stats":[{"origin":"Pim","entry_count":1}]},
 "v6":{"entry_count":0,"protocol_stats":[]}}

The entries held in each address family's table, in total and per origin. An origin holding no entries has no row. A VRF the mRIB does not know returns null.

All entries in the mRIB

The walk selects one address-family table and defaults to IPv4:

flock@r1:~$ flockc mrib vrf default walk
{"entries":[{"source":"192.0.2.10","group":"232.1.1.1","origin":"Pim",
             "iif":{"intf_id":12,"intf_name":"r1-n12"},
             "oifs":[{"intf_id":14,"intf_name":"r1-n14"}],
             "last_modified":"2026-08-03T09:14:22.481Z"}],
 "finished":true}

iif is the incoming (RPF) interface and oifs the outgoing interfaces, listed by interface name. Each interface carries its id and its name; the name is null only for an interface the system has not reported.

Entries come in (S,G) order. A large table can be walked a chunk at a time: --max-entries N returns at most N entries, and --start-from SOURCE,GROUP resumes after the entry a previous chunk ended on. finished is true when no entries follow the last one returned, including when the chunk is exactly full. A walk that finds no entries -- an empty table, or a resume at or past the last entry -- returns none with finished set.

flock@r1:~$ flockc mrib vrf default walk --max-entries 100 --start-from 192.0.2.10,232.1.1.1

last_modified records when that entry's forwarding state last changed, to millisecond resolution. A change that leaves the entry identical does not move it. Interface names are re-read on each report and are not part of the state it tracks.

A single (S,G)

flock@r1:~$ flockc mrib vrf default lookup 192.0.2.10 232.1.1.1
{"source":"192.0.2.10","group":"232.1.1.1","origin":"Pim",
 "iif":{"intf_id":12,"intf_name":"r1-n12"},
 "oifs":[{"intf_id":14,"intf_name":"r1-n14"}],
 "last_modified":"2026-08-03T09:14:22.481Z"}

An (S,G) the mRIB does not hold returns null. The source and the group must be of the same address family.

IPv6

--af ipv6 selects the IPv6 table. The mRIB holds IPv6 entries, but the Linux multicast forwarding cache is IPv4-only, so an IPv6 (S,G) has no forwarding-plane path and the table is normally empty.

mRIB Operation

Help

flockc mrib --help

mRIB stats

flockc mrib vrf <vrf-name> stats

mRIB walk

flockc mrib vrf <vrf-name> walk [--af ipv4 | ipv6] [--max-entries <n>] [--start-from <source>,<group>]

mRIB lookup

flockc mrib vrf <vrf-name> lookup <source> <group>