H3C交换机上如何做DHCP的IP和MAC绑定

2024-12-03 03:57:33
推荐回答(2个)
回答1:

需要MAC+IP绑定比较麻烦,需要通过定义地址池来为每一个PC机分配地址,而且每个地址池只能为一台PC分配IPIP地址,这就要求有多少台PC就需要定义多少个地址池,下面是一个实例,具体命令如下:
[SwitchA] dhcp server ip-pool 0
[SwitchA-dhcp-pool-0] static-bind ip-address 10.1.1.5
[SwitchA-dhcp-pool-0] static-bind mac-address 000f-e200-0002
[SwitchA-dhcp-pool-0] gateway-list 10.1.1.254
[SwitchA-dhcp-pool-0] dns-list 202.96.209.133 202.96.209.5

[SwitchA] dhcp server ip-pool 1
[SwitchA-dhcp-pool-1] static-bind ip-address 10.1.1.6
[SwitchA-dhcp-pool-1] static-bind mac-address 000f-e200-0003
[SwitchA-dhcp-pool-1] gateway-list 10.1.1.254
[SwitchA-dhcp-pool-0] dns-list 202.96.209.133 202.96.209.5

回答2:

最好是固定IP地址,又不会出现DHCP地址问题。