Chapter 2 IGMP Snooping Configuration
Commands
Syntax
display igmp-snooping configuration
View
Any view
Parameter
None
Description
Use the display igmp-snooping
configuration command to display IGMP Snooping configuration information.
When IGMP Snooping is enabled on a switch,
this command displays the following information: IGMP Snooping status, aging
time of the router port, maximum query response timeout time, and aging time of
multicast group member ports.
Related command: igmp-snooping.
Example
# Display IGMP Snooping configuration
information on a switch.
<H3C> display igmp-snooping
configuration
Enable IGMP-Snooping.
The router port timeout is 105
second(s).
The max response timeout is 1
second(s).
The host port timeout is 260
second(s).
The above information shows: IGMP Snooping
is enabled, the aging time of the router port is 105 seconds, the maximum query
response timeout time is one second, and the aging time of multicast group
member ports is 260 seconds.
Syntax
display igmp-snooping group [ vlan vlan-id ]
View
Any view
Parameter
vlan-id: ID
of the specified VLAN.
Description
Use the display igmp-snooping group
command to display information about the IP multicast groups and MAC multicast
groups in a specific VLAN (with vlan vlan-id specified) or all
VLANs (without vlan vlan-id specified).
This command displays the following
information: VLAN ID, router port, IP multicast group address, member ports
included in the IP multicast group, MAC multicast group, MAC multicast group
address, and member ports included in the MAC multicast group.
Example
# Display information about the multicast
groups in VLAN 2.
<H3C> display igmp-snooping
group vlan 2
Total 1 IP Group(s).
Total 1 MAC Group(s).
Vlan(id):2.
Total 1 IP Group(s).
Total 1 MAC Group(s).
Static router port(s):
Dynamic router port(s):
IP group(s):the following ip
group(s) match to one mac group.
IP group address:225.1.1.1
Host
port(s):GigabitEthernet2/0/1
MAC group(s):
MAC group
address:0100-5e01-0101
Host
port(s):GigabitEthernet2/0/1
The information above means:
l
Multicast groups exist in VLAN 2.
l
The address of the IP multicast group is
255.1.1.1.
2.1.3 display igmp-snooping statistics
Syntax
display igmp-snooping statistics
View
Any view
Parameter
None
Description
Use the display igmp-snooping statistics
command to display IGMP Snooping message statistics.
This command displays the following
information: the numbers of received IGMP general query messages, received IGMP
group-specific query messages, received IGMPv1 report messages, received IGMPv2
report messages, received IGMP leave messages and received IGMP error messages,
and the number of sent IGMP group-specific query messages.
Related command: igmp-snooping.
Example
# Display IGMP Snooping message statistics.
<H3C> display igmp-snooping
statistics
Received IGMP general query packet(s)
number:0.
Received IGMP specific query
packet(s) number:0.
Received IGMP V1 report packet(s)
number:0.
Received IGMP V2 report packet(s)
number:0.
Received IGMP leave packet(s)
number:0.
Received error IGMP packet(s)
number:0.
Sent IGMP specific query packet(s)
number:0.
The information above shows that IGMP
Snooping-enabled switches receive:
l
zero IGMP general query messages
l
zero IGMP group-specific query messages
l
zero IGMPv1 report messages
l
zero IGMPv2 report messages
l
zero IGMP leave messages
l
zero IGMP error messages
IGMP Snooping-enabled switches send:
l
zero IGMP specific query messages
Syntax
display multicast-vlan [ vlan-id ]
View
Any view
Parameter
vlan-id: ID
of the specified VLAN.
Description
Use the display multicast-vlan
command to display the configuration information of the multicast VLAN.
If the vlan-id argument is not
provided when the command is executed, the configuration information of all the
VLANs in the network is displayed.
Example
# Display the configuration information of
multicast VLAN 2.
<H3C> display multicast-vlan 2
multicast vlan 2's subvlan list:
Vlan 1024
The information above means:
l
Multicast VLAN 2 exists
l
VLAN 1024 is the subvlan of multicast VLAN 2
Syntax
igmp-snooping { enable | disable }
View
System view
Parameter
enable:
Enables the IGMP Snooping feature.
disable:
Disables the IGMP Snooping feature.
Description
Use the igmp-snooping enable command
to enable the IGMP Snooping feature.
Use the igmp-snooping disable
command to disable the IGMP Snooping feature.
By default, the IGMP Snooping feature is
disabled.
Example
# Enable the IGMP Snooping feature on the
switch.
<H3C> system-view
System View: return to User View with
Ctrl+Z.
[H3C] igmp-snooping enable
Enable IGMP-Snooping ok.
Syntax
igmp-snooping fast-leave [ vlan vlan-list ]
undo igmp-snooping fast-leave [ vlan vlan-list ]
View
System view, Ethernet port view
Parameter
vlan-list:
Multiple VLANs in the form of vlan-list = { vlan-id [ to vlan-id
] } & < 1-10 >. The vlan-id argument is the ID of a VLAN, in
the range of 1 to 4094. &<1-10> means that you can provide this
argument repeatedly for up to ten times.
Description
Use the igmp-snooping fast-leave
command to enable the IGMP fast leave feature.
Use the undo igmp-snooping
fast-leave command to disable the IGMP fast leave feature.
By default, the IGMP fast leave feature is
disabled.
Normally, when a port receives an IGMP
Leave message, the IGMP Snooping-enabled switch does not immediately remove the
port from the multicast group, but sends a group-specific query message. If no
response is received in a given period, it then removes the port from the
multicast group.
If this command is executed, when a port
receives an IGMP Leave message, the IGMP Snooping-enabled switch directly
removes the port from the multicast group. When the port has only one user, the
IGMP fast leave feature can save bandwidth.
l
This feature is applicable to only
IGMPv2-enabled clients.
l
When this feature is enabled, if one of the
multiple users on a port leaves, the multicast services for the other users in
the same multicast group may be interrupted.
Example
# Enable the IGMP fast leave feature on
Ethernet1/0/1.
<H3C> system-view
System View: return to User View with
Ctrl+Z.
[H3C] interface Ethernet 1/0/1
[H3C-Ethernet1/0/1] igmp-snooping
fast-leave
2.1.7 igmp-snooping
group-limit
Syntax
igmp-snooping
group-limit limit [ vlan vlan-list [
overflow-replace ] | overflow-replace ]
undo igmp-snooping
group-limit [ vlan vlan-list ]
View
Ethernet port view
Parameter
limit:
Maximum number of multicast groups the port can join, in the range of 1 to 256.
overflow-replace:
Permits a new multicast group to replace an existing multicast group. The multicast
group with the lowest IP address is replaced preferentially.
vlan-list:
Multiple VLANs in the form of vlan-list = { vlan-id [ to vlan-id
] } & < 1-10 >. The vlan-id argument is the ID of a VLAN, in
the range of 1 to 4094. &<1-10> means that you can provide this
argument repeatedly for up to ten times.
Description
Use the igmp-snooping group-limit
command to define the maximum number of multicast groups the port can join.
Use the undo igmp-snooping group-limit
command to restore the default setting.
By default, there is no limit on the number
of multicast groups the port can join.
Example
# Allow Ethernet1/0/1 to join up to 200
multicast groups.
<H3C> system-view
System View: return to User View with
Ctrl+Z.
[H3C] interface Ethernet 1/0/1
[H3C-Ethernet1/0/1] igmp-snooping
group-limit 200
2.1.8 igmp-snooping
group-policy
Syntax
igmp-snooping
group-policy acl-number [ vlan vlan-list ]
undo igmp-snooping
group-policy [ vlan vlan-list ]
View
System view, Ethernet port view
Parameter
acl-number: Basic
ACL number, in the range of 2000 to 2999.
vlan-list:
Multiple VLANs in the form of vlan-list = { vlan-id [ to vlan-id
] } & < 1-10 >. The vlan-id argument is the ID of a VLAN, in
the range of 1 to 4094. &<1-10> means that you can provide this
argument repeatedly for up to ten times.
Description
Use the igmp-snooping group-policy
command to configure an IGMP Snooping filtering ACL.
Use the undo igmp-snooping
group-policy command to remove the IGMP Snooping filtering ACL.
By default, no IGMP Snooping filtering ACL
is configured.
You can use the IGMP Snooping filter
feature to configure multicast filtering ACLs for users connected to different
switch ports so as to limit the multicast programs the users can access. With
this feature enabled, you can treat different VoD users differentiatedly by
allowing them to access the multicast programs in different multicast groups.
In practice, when a user orders a multicast
program, an IGMP host report message is generated. When the message arrives at
the switch, the switch examines the multicast filtering ACL configured on the
access port to determine whether the port can join the corresponding multicast
group or not. If yes, it adds the port to the forwarding port list of the
multicast group. If not, it drops the IGMP host report message and does not
forward the corresponding data stream to the port. In this way, you can control
the multicast programs that users can access.
An ACL rule defines a multicast address or
a multicast address range (for example 224.0.0.1 to 239.255.255.255) and is
used to:
l
Allow the port(s) to join only the multicast
group(s) defined in the permit rule.
l
Inhibit the port(s) from joining the multicast
group(s) defined in the deny rule.
l
A port can belong to multiple VLANs. But for each
VLAN on the port, you can configure only one ACL.
l
If the port does not belong to the specified
VLAN, the filtering ACL configured for the VLAN does not take effect on the
port.
l
If no ACL rule is configured in the command, the
system will reject the multicast packets addressed to all the multicast groups.
l
Since most devices broadcast unknown multicast
packets, this feature is often used together with the unknown multicast packet
drop feature to prevent multicast streams from being broadcasted to a filtered
port as unknown multicast streams.
Example
# Configure ACL 2000 to allow users on
Ethernet 1/0/1 to access the multicast streams in multicast groups ranging from
225.0.0.0 to 225.255.255.255.
l
Configure ACL 2000.
<H3C> system-view
System View: return to User View with
Ctrl+Z.
[H3C] acl number 2000
[H3C-acl-basic-2000] rule permit
source 225.0.0.0 0.255.255.255
[H3C-acl-basic-2000] quit
l
Create VLAN 2 and add Ethernet 1/0/1 port to
VLAN 2.
[H3C] vlan 2
[H3C-vlan2] port Ethernet 1/0/1
Gigabit[H3C-vlan2] quit
l
Configure ACL 2000 on Ethernet 1/0/1 to allow
VLAN 2 to join only the IGMP multicast groups defined in ACL 2000.
[H3C] interface Ethernet 1/0/1
[H3C-Ethernet1/0/1] igmp-snooping
group-policy 2000 vlan 2
[H3C-Ethernet1/0/1] quit
# Configure ACL 2001 to allow users on
Ethernet 1/0/2 to access the multicast streams in any multicast group except
multicast groups ranging from 225.0.0.0 to 225.0.0.255.
l
Configure ACL 2001.
[H3C] acl number 2001
[H3C-acl-basic-2001] rule deny source
225.0.0.0 0.0.0.255
[H3C-acl-basic-2001] rule permit
source any
[H3C-acl-basic-2001] quit
l
Create VLAN 2 and add Ethernet 1/0/2 to VLAN 2.
[H3C] vlan 2
[H3C-vlan2] port Ethernet 1/0/2
[H3C-vlan2] quit
l
Configure ACL 2001 on Ethernet 1/0/2 to allow
VLAN 2 to join any IGMP multicast groups except those defined in ACL 2001.
[H3C] interface Ethernet 1/0/2
[H3C-Ethernet1/0/2] igmp-snooping
group-policy 2001 vlan 2
Syntax
igmp-snooping host-aging-time seconds
undo igmp-snooping host-aging-time
View
System view
Parameter
seconds:
Aging time of multicast group member ports, in the range of 200 to 1000 in
seconds.
Description
Use the igmp-snooping host-aging-time
command to configure the aging time of multicast group member port.
Use the undo igmp-snooping
host-aging-time command to restore the default aging time.
By default, the aging time of multicast
group member ports is 260 seconds.
The aging time of multicast group member
ports determines the refresh frequency of multicast group members. In an
environment where multicast group members change frequently, a relatively
shorter aging time is required.
Related command: igmp-snooping.
Example
# Set the aging time of multicast group
member ports to 300 seconds.
<H3C> system-view
System View: return to User View with
Ctrl+Z.
[H3C] igmp-snooping host-aging-time
300
Syntax
igmp-snooping max-response-time seconds
undo igmp-snooping max-response-time
View
System view
Parameter
seconds:
Query response timeout time, in the range of 1 to 25 in seconds.
Description
Use the igmp-snooping max-response-time
command to configure the maximum query response timeout time.
Use the undo igmp-snooping
max-response-time command to restore the default timeout time.
By default, the maximum query response
timeout time is 10 seconds.
The configured maximum query response
timeout time determines how long the switch can wait for a response to an IGMP
Snooping query message.
Related command: igmp-snooping, igmp-snooping
router-aging-time.
Example
# Set the maximum query response timeout
time to 15 seconds.
<H3C> system-view
System View: return to User View with
Ctrl+Z.
[H3C] igmp-snooping max-response-time
15
Syntax
igmp-snooping
report-aggregation
View
System view
Parameter
None
Description
Use the igmp-snooping
report-aggregation command to enable suppression on Layer 2 multicast IGMP
report messages. In an IGMP Snooping-enabled VLAN, only one IGMP report message
is sent to the upstream router port during an interval.
Use the undo igmp-snooping
report-aggregation command to disable suppression on Layer 2 multicast IGMP
report messages.
By default, suppression on IGMP report
messages is disabled.
l
IGMP snooping must be enabled globally before
the suppression on IGMP report messages is enabled.
l
If IGMP snooping is disabled globally, the
suppression on IGMP report messages is disabled simultaneously.
Example
# Enable suppression on Layer 2 multicast
IGMP report messages on the switch.
<H3C> system-view
System View: return to User View with
Ctrl+Z.
[H3C] igmp-snooping enable
[H3C] igmp-snooping
report-aggregation
2.1.12 igmp-snooping router-aging-time
Syntax
igmp-snooping router-aging-time seconds
undo igmp-snooping router-aging-time
View
System view
Parameter
seconds:
Aging time of router ports, in the range of 1 to 1000 in seconds.
Description
Use the igmp-snooping router-aging-time
command to configure the aging time of router ports.
Use the undo igmp-snooping
router-aging-time command to restore the default aging time of router
ports.
By default, the aging time of router ports
is 105 seconds.
The router port here refers to the port
connecting the Layer 2 switch to the router. The Layer 2 switch receives IGMP
general query messages from the router through this port. The aging time of the
router port must be a value about 2.5 times of the general query interval.
Related command: igmp-snooping
max-response-time, and igmp-snooping.
Example
# Set the aging time of the IGMP
Snooping-enabled router port to 500 seconds.
<H3C> system-view
System View: return to User View with
Ctrl+Z.
[H3C] igmp-snooping router-aging-time
500
Syntax
multicast-vlan
enable
undo multicast-vlan enable
View
VLAN view
Parameter
None
Description
Use the multicast-vlan enable
command to configure the current VLAN as a multicast VLAN.
Use the undo multicast-vlan
enable command to disable the current VLAN from being a multicast VLAN.
By default, multicast VLANs are disabled.
Caution:
l
A multicast VLAN cannot be configured as a
multicast sub-VLAN.
l
A multicast sub-VLAN cannot be configured as a
multicast VLAN.
l
A multicast sub-VLAN cannot be configured as the
sub-VLAN of other multicast VLANs.
l
One multicast sub-VLAN is corresponding to only
one multicast VLAN.
l
If multicast routing is enabled on a VLAN
interface, the corresponding VLAN cannot be configured as a multicast VLAN.
Example
# Configure VLAN 2 as a multicast VLAN.
<H3C> system-view
Enter system view, return to user
view with Ctrl+Z
[H3C] igmp-snooping enable
[H3C] vlan 2
[H3C-vlan2] multicast-vlan enable
Syntax
multicast-vlan
vlan-id subvlan vlan-list
undo multicast-vlan
vlan-id subvlan vlan-list
View
System view
Parameter
vlan-id: ID
of the specified VLAN.
vlan-list:
Multiple VLANs in the form of vlan-list = { vlan-id [ to vlan-id
] } & < 1-10 >. The vlan-id argument is the ID of a VLAN, in
the range of 1 to 4,094. &<1-10> means that you can provide the
argument repeatedly for up to ten times.
Description
Use the multicast-vlan subvlan
command to configure one or multiple VLANs as the sub-VLAN(s) of the multicast
VLAN.
Use the undo multicast-vlan
subvlan command to cancel the sub-VLANs of the multicast VLAN.
By default, no sub-VLAN is configured for a
multicast VLAN.
Caution:
l
A multicast VLAN cannot be configured as a
multicast sub-VLAN.
l
A multicast sub-VLAN cannot be configured as a
multicast VLAN.
l
A multicast sub-VLAN cannot be configured as the
sub-VLAN of other multicast VLANs.
l
One multicast sub-VLAN is corresponding to only
one multicast VLAN.
l
If multicast routing is enabled on a VLAN
interface, the corresponding VLAN cannot be configured as a multicast VLAN.
Example
# Configure VLAN 2 through VLAN 5 as the
sub-VLANs of multicast VLAN 10.
<H3C> system-view
Enter system view, return to user
view with Ctrl+Z
[H3C] igmp-snooping enable
[H3C] vlan 10
[H3C-vlan10] igmp-snooping enable
[H3C-vlan10] multicast-vlan enable
[H3C-vlan10] quit
[H3C] multicast-vlan 10 subvlan 2 to
5
Syntax
reset igmp-snooping statistics
View
User view
Parameter
None
Description
Use the reset igmp-snooping statistics
command to clear IGMP Snooping statistics.
Related command: igmp-snooping.
Example
# Clear IGMP Snooping statistics.
<H3C> reset igmp-snooping
statistics
Chapter 3 Common
IP Multicast Configuration Commands
Syntax
display mpm forwarding-table [ group-address | source-address ]
View
Any view
Parameter
group-address: Multicast group address to specify a multicast group, in the range
of 224.0.0.0 to 239.255.255.255.
source-address: IP address of the multicast source.
Description
Use the display mpm forwarding-table
command to display the information about multicast forwarding tables containing
port information.
Only the matched (S, G) entries are
displayed when the group address or source address is specified. Otherwise, the
command displays all the entries.
If you want to query the information about
multicast forwarding tables without port information, you can use the display
multicast forwarding-table command.
Example
# Query the information about the multicast
forwarding table containing port information.
<H3C> display mpm
forwarding-table
Multicast Forwarding Cache Table
Total 1 entry(entries)
00001. (120.0.0.2, 225.0.0.2)
iif Vlan-interface1200
1 oif(s):
Vlan-interface32
GigabitEthernet3/0/19
Total 1 entry(entries) Listed
Multicast Forwarding Cache Table
Total 1 entry(entries)
00001. (10.11.113.110, 226.1.1.1)
in-vlan Vlan1
2 out-vlan(s):
Vlan20
Ethernet5/1/33
Vlan10
Ethernet5/1/31
Total 1 entry(entries) Listed
Table 3-1 describes the fields in the displayed information above:
Table 3-1 Description on the fields of the display mpm forwarding-table command
|
Field
|
Description
|
|
Multicast Forwarding Cache Table
|
Multicast forwarding table
|
|
Total 1 entries
|
Total number of entries
|
|
00001
|
Serial number of an entry
|
|
(120.0.0.2, 225.0.0.2)
|
(S, G), namely, (source address, group
address)
|
|
iif Vlan-interface1200
|
The incoming VLAN of the multicast
forwarding table is VLAN 1200.
|
|
2 out-vlan(s):
|
There are two outgoing VLANs in the
multicast forwarding table.
|
|
2 out-vlan(s):
Vlan20
Ethernet5/1/33
Vlan10
Ethernet5/1/31
|
The first outgoing VLAN is VLAN 20, with
the outgoing port Ethernet5/1/33.
The second outgoing VLAN is VLAN 10, with
the outgoing port Ethernet5/1/31.
|
|
Total 1 entry(entries) Listed
|
One (S, G) entry is listed.
|
Syntax
display mpm group [ vlan vlan-id [ ip-address ] ]
View
Any view
Parameter
vlan
vlan-id: Specifies the VLAN where the multicast
group to be viewed resides. If this keyword is not specified, the command
displays the multicast group information in all VLANs.
ip-address:
IP address of the multicast group to be viewed.
Description
Use the display mpm group command to
display the information about the IP multicast groups and MAC multicast groups
in the specified VLAN or all the VLANs on the switch.
The displayed information includes:
l
VLAN ID
l
Router port
l
Address of the IP multicast group
l
Member ports in the IP multicast group
l
MAC multicast group
l
Address of the MAC multicast group
l
Member ports in the MAC multicast group
Caution:
l
The fields of this command are similar to those
of the display igmp group command, except that the information of the
specific ports is added.
l
The fields of this command are the same as those
of the display igmp-snooping group command except that the VLANs to be
viewed are of different attributes.
l
The display igmp-snooping group
command displays the information about ports joining in layer-2 multicast
groups in IGMP Snooping-enabled VLANs, while the display mpm group
command displays the information about ports joining in layer-3 multicast
groups in IGMP-enabled VLANs.
Example
# Display the information about multicast
groups in VLAN 2.
<H3C> display mpm group vlan
1200
Total 2 IP Group(s).
Total 2 MAC Group(s).
Vlan(id):1200.
Total 2 IP Group(s).
Total 2 MAC Group(s).
Static router port(s):
Dynamic router port(s):
IP group(s):the following ip group(s)
match to one mac group.
IP group address:228.0.0.1
Host
port(s):GigabitEthernet2/0/12
MAC group(s):
MAC group
address:0100-5e00-0001
Host
port(s):GigabitEthernet2/0/12
IP group(s):the following ip
group(s) match to one mac group.
IP group address:228.0.0.0
Host
port(s):GigabitEthernet2/0/12
MAC group(s):
MAC group
address:0100-5e00-0000
Host
port(s):GigabitEthernet2/0/12
Table 3-2 Description on the fields of
the display mpm group command
|
Field
|
Description
|
|
Vlan(id):
|
Multicast
groups in the specified VLAN
|
|
Static router port(s):
|
Static router port(s):
|
|
Dynamic router port(s):
|
Dynamic router port(s):
|
|
IP group(s): the following ip group(s)
match to one mac group.
|
IP multicast groups: the following IP
multicast groups match the same MAC multicast group.
|
|
IP group address:
|
The addresses of the IP multicast group.
|
|
Host port(s):
|
The host port in the IP multicast group:
|
|
MAC group address:
|
The address of the MAC multicast group:
|
Syntax
display multicast forwarding-table [ group-address [ mask {
group-mask | mask-length }
] | source-address [ mask { group-mask
| mask-length } ] |
incoming-interface { interface-type interface-number
] register } ]*
View
Any view
Parameter
group-address: Address of the specified multicast group, in the range of
224.0.0.0 to 239.255.255.255.
source-address: Unicast IP address of the multicast source.
incoming-interface:
Specifies the incoming interface of the specified multicast forwarding entry.
register:
Specifies the registration VLAN interface of the PIM-SM protocol.
Description
Use the display multicast forwarding-table
command to display the information about MAC forwarding tables.
Related command: display multicast
routing-table.
Example
# Display the information about MAC
forwarding tables.
<H3C> display multicast
forwarding-table
Multicast Forwarding Cache Table
Total 1 entry: 0 entry created by IP,
1 entry created by protocol
00001. (10.0.0.4, 225.1.1.1), iif
Vlan-interface2, 0 oifs,
Protocol Create
Matched 122 pkts(183000 bytes),
Wrong If 0 pkts
Forwarded 122 pkts(183000 bytes)
Total 1 entry Listed
Table 3-3 describes the displayed information above.
Table 3-3 Description
on the fields of the display multicast forwarding-table command
|
Field
|
Description
|
|
Multicast Forwarding Cache Table
|
Multicast forwarding table
|
|
Total 1 entries
|
Total number of entries
|
|
00001
|
Serial number of an entry
|
|
(10.0.0.4, 225.1.1.1)
|
(S, G), namely, (source address, group
address)
|
|
iif Vlan-interface2, 0 oifs
|
<