1、其他廠商:
在華為,華三等設備上,我們都有“黑洞MAC地址表項” 的配置,其特點是手動配置、不會老化,且重啟后也不會丟失。例如如下示例:
黑洞表項是特殊的靜態MAC地址表項,丟棄含有特定源MAC地址或目的的MAC地址的數據幀;防止無用的MAC地址表項占用MAC地址表;將非信任的MAC配置為黑洞MAC地址,當設備收到目的或源MAC地址為黑洞里的MAC時直接丟棄,防止網絡攻擊。
在MAC地址已滿的情況下配置靜態或黑洞MAC表時,如果表中存在對應的要配置的表則自動覆蓋;如果不存在則無法添加靜態或黑洞MAC表
在刪除MAC地址表項時必須指定接口、vlan,否則會刪除所有接口或vlan下的表項。
【摘自:http://www.023wg.com/huawei/33.html】
2、思科配置
在思科的交換機上,也可以有類似的配置,該命令如下:
This example shows how to enable unicast MAC address filtering and how to configure drop packets that have a source or destination address of c2f3.220a.12f4. When a packet is received in VLAN 4 with this MAC address as its source or destination, the packet is dropped:
Switch(config)# mac address-table static c2f3.220a.12f4 vlan 4 drop
可以按照以下步驟配置設備以丟棄源或目標單播靜態地址:
Device> enable Device# configure terminal Device(config)# mac address-table static c2f3.220a.12f4 vlan 4 drop
思科官網可查詢的配置文檔(15.0(2)EX 之后),應該都支持如上配置。