端口安全实验:
思路:
1、将交换机三个端口设置为接入模式,属于vlan 10
2、在这3个接口启动端口安全
3、配置粘贴功能sticky特性
4、配置端口违规
5、配置MAC地址flapping关闭g0/0/1端口
拓扑图如图所示:
(图中各个PC机的MAC地址可以直接双击PC机在基础配置中进行查看)
交换机配置命令如下:
system-view
vlan 6
interface g0/0/1
port link-type access
port default vlan 6
interface g0/0/2
port link-type access
port default vlan 6
interface g0/0/3
port link-type access
port default vlan 6
mac-address flapping detection
interface g0/0/1
port-security enable
port-security max-mac-num 2
port-security mac-address sticky
port-security protect-action shutdown
mac-address flapping trigger error-down
interface g0/0/2
port-security enable
port-securi