默认状态下,未知目的MAC地址的泛洪包被允许从端口向外传输。如果未知的单播和多播通信被转发到保护端口,将导致安全问题。可以采用阻塞端口的方式,防止未知的单播和多播通信被转在端口间转发。
第一步:进入全局配置模式。
Switch# config terminal
第二步:指定欲配置的接口。
Switch(config)# interface interface-id
第三步:禁止未知多播从该端口向外传输。
Switch(config-if)# switchport block multicast
第四步:禁止未知单播从该端口向外传输。
Switch(config-if)# switchport block unicast
第五步:返回特权配置模式。
Switch(config-if)# end
第六步:显示并校验该接口当前的配置。
Switch# show interfaces interface-id switchport
第七步:保存配置。
Switch# copy running-config startup-config