如何从 Cisco 设备获取 DHCP 范围信息?(IOS 12)

Hop*_*00b 2 networking dhcp cisco

我正在尝试在具有一堆子网和 VLAN 等的相当大的网络上跟踪设备和网络信息,其中大部分由 Cisco [企业级] 交换机或路由器提供 DHCP。在这方面,我希望找出各种 DHCP 池/范围是什么,但我能找到的所有信息都是关于如何使用 Cisco IOS 配置 DHCP,这没有帮助,因为我不想更改范围,只需显示它们当前的内容即可。

我可以做一个show ip dhcp binding获取 DHCP 客户端列表,以及它们的 IP 并猜测 DHCP IP 的有效范围是什么,但这是非常不可取的......那么显示该信息的命令是什么(不改变现有配置)?

eww*_*ite 5

从相关设备,尝试show ip dhcp pool。要显示排除项,请尝试show run | i excluded-addresses

以下输出来自 Cisco 4507 交换机。

CORE#show ip dhcp pool

Pool VOICE :
 Utilization mark (high/low)    : 100 / 0
 Subnet size (first/next)       : 0 / 0 
 Total addresses                : 254
 Leased addresses               : 42
 Excluded addresses             : 101
 Pending event                  : none
 1 subnet is currently in the pool :
 Current index        IP address range                    Leased/Excluded/Total
 192.168.122.234      192.168.122.1    - 192.168.122.254   42    / 101   / 254  


Pool GUEST :
 Utilization mark (high/low)    : 100 / 0
 Subnet size (first/next)       : 0 / 0 
 Total addresses                : 254
 Leased addresses               : 9
 Excluded addresses             : 103
 Pending event                  : none
 1 subnet is currently in the pool :
 Current index        IP address range                    Leased/Excluded/Total
 192.168.111.165      192.168.111.1    - 192.168.111.254   9     / 103   / 254  
Run Code Online (Sandbox Code Playgroud)

和排除:

CORE#show run | i excluded-addresses
ip dhcp excluded-address 192.168.122.1 192.168.122.50
ip dhcp excluded-address 192.168.122.100 192.168.122.150
ip dhcp excluded-address 192.168.111.1 192.168.111.50
ip dhcp excluded-address 192.168.111.100 192.168.111.150
Run Code Online (Sandbox Code Playgroud)