Linux, FreeBSD, Juniper, Cisco / Network security articles and troubleshooting guides

FreeBSD list interface multicast group membership
Page 1 of 1

Author:  mandrei99 [ Tue Dec 03, 2013 9:02 am ]
Post subject:  FreeBSD list interface multicast group membership

In a previous thread, I used "iperf" command to join a multicast group on FreeBSD command line.

To actually see the status of the group, use "ifmcstat". Quote:
ifmcstat -- dump multicast group management statistics per interface

ifmcstat [-i interface] [-f address-family] [-v] [-K] [-M core]
[-N system]

The ifmcstat command dumps multicast group information from the kernel.

The following options are supported:

-i interface
specifies the interface to be displayed.

-f address-family
specifies the address family to be displayed; inet, inet6 and
link are supported.

-v specifies that link-layer memberships should be printed; they
are suppressed by default. It may not be specified for -f
link. Source lists for each group will also be printed.

If specified twice, and kvm(3) is in use, the control plane
timers for each interface and the source list counters for
each group will also be printed.

The following options are only available if ifmcstat has been built with
support for kvm(3):

-K attempts to use kvm(3) to retrieve the multicast group infor-

-M core extracts values associated with the name list from the speci-
fied core, instead of the default /dev/kmem.

-N system extracts the name list from the specified kernel instead of
the default, which is the kernel image the system has booted

ifmcstat will always print the embedded scope IDs of IPv6 multicast group
memberships. This is because memberships are always scoped to an inter-

When run with the -v option, ifmcstat may print multicast MAC addresses
twice if they are referenced by a layer 3 protocol.

When run with kvm(3) support, the names of all interfaces configured in
the system will be printed in the first column of output, even if no mul-
ticast group memberships are present on those interfaces. The output may
also be slightly different, as the kernel data structures are being tra-
versed with minimal post-processing of the output.

When built without kvm(3) support, the information displayed by ifmcstat
is more limited. This support is recommended for debugging purposes. It
requires super-user privilege if used to inspect a running kernel.

Example of showing family inet multicast group membership for an interface (if any):
# ifmcstat  -f inet -v
        igmpv3 flags=0<> rv 3 qi 0 qri 1 uri 3
                group mode undefined
                        mcast-macaddr 01:00:5e:00:00:01
                group mode exclude
                        mcast-macaddr 01:00:5e:00:00:01
        igmpv3 flags=0<> rv 3 qi 0 qri 1 uri 3
                group mode exclude
                        mcast-macaddr 01:00:5e:00:00:01
        igmpv3 flags=0<> rv 2 qi 125 qri 10 uri 3
                group mode exclude

So I can see that on em0 interface, multicast group membership join requests are sent for multicast group.

Note: '-v' switch is not in FreeBSD7. This switch also displays the multicast MAC address corresponding to the group.

Page 1 of 1 All times are UTC - 5 hours [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group