R3303-HP HSR6800 Routers Layer 2 - LAN Switching Command Reference
78
• stp root primary
stp root-protection
Use stp root-protection to enable the root guard function on the ports.
Use undo stp root-protection to disable the root guard function on the ports.
Syntax
stp root-protection
undo stp root-protection
Default
The root guard function is disabled.
Views
Ethernet interface view, port group view, Layer 2 aggregate interface view
Default command level
2: System level
Usage guidelines
Configured in Ethernet interface view, the setting takes effect only on the interface.
Configured in port group view, the setting takes effect on all member ports in the port group.
Configured in Layer 2 aggregate interface view, the setting takes effect only on the aggregate interface.
Configured on a member port in an aggregation group, the setting takes effect only after the port leaves
the aggregation group.
You cannot configure root guard and loop guard on a port at the same time.
Examples
# Enable the root guard function for GigabitEthernet 4/0/1.
<Sysname> system-view
[Sysname] interface GigabitEthernet 4/0/1
[Sysname-GigabitEthernet4/0/1] stp root-protection
Related commands
stp loop-protection
stp tc-protection
Use stp tc-protection enable to enable the TC-BPDU attack guard function for the device.
Use stp tc-protection disable to disable the TC-BPDU attack guard function for the device.
Syntax
stp tc-protection enable
stp tc-protection disable
Default
The TC-BPDU attack guard function is enabled.