| 场景 | 替换设备、MAC 溯源、链路对接核对 |
|---|---|
| 适用 | 全部设备 |
| 命令族 | display interface(MAC 字段)/ show interfaces / display interface |
华为 VRP
华为 VRP
<Huawei> display interface GigabitEthernet 0/0/1 | include MAC
! 输出如:Hardware address is 0011-2233-4455
[Huawei-GigabitEthernet0/0/1] mac-address 0011-2233-4456 ! 修改(谨慎)思科 IOS
思科 IOS
SW-CORE-01# show interfaces GigabitEthernet1/0/1 | include address
! 输出如:hardware is Gigabit Ethernet, address is 0011.2233.4455
SW-CORE-01(config-if)# mac-address 0011.2233.4456H3C Comware
H3C Comware
<H3C> display interface GigabitEthernet 1/0/1 | include MAC
! 输出如:Hardware address is 0011-2233-4455
[H3C-GigabitEthernet1/0/1] mac-address 0011-2233-4456格式对照:华为/H3C xxxx-xxxx-xxxx,思科 xxxx.xxxx.xxxx(同一地址两种写法)。物理口 MAC 默认取设备/单板基地址,改 MAC 后记得同步更新上游静态绑定与安全策略。