Cisco DHCP on Vlans
Anzeige Vlan Interfaces mit IP
- switch-gelb#show running-config
interface Vlan1 ip address 192.168.240.154 255.255.248.0 ! interface Vlan20 ip address 192.168.20.1 255.255.255.0 ! interface Vlan30 ip address 192.168.30.1 255.255.255.0 ! interface Vlan40 ip address 192.168.40.1 255.255.255.0 !
DHCP Pools anlegen
- switch-gelb#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Adressen rausnehmen
- switch-gelb(config)#ip dhcp excluded-address 192.168.20.1 192.168.20.50
- switch-gelb(config)#ip dhcp excluded-address 192.168.30.1 192.168.30.50
- switch-gelb(config)#ip dhcp excluded-address 192.168.40.1 192.168.40.50
DHCP konfiguren
- switch-gelb(config)#ip dhcp pool dpool20
- switch-gelb(dhcp-config)#network 192.168.20.0 255.255.255.0
- switch-gelb(dhcp-config)#default-router 192.168.20.1
- switch-gelb(dhcp-config)#dns-server 192.168.240.200
- switch-gelb(dhcp-config)#work.xinux.org
- switch-gelb(dhcp-config)#ip dhcp pool dpool30
- switch-gelb(dhcp-config)#network 192.168.30.0 255.255.255.0
- switch-gelb(dhcp-config)#default-router 192.168.30.1
- switch-gelb(dhcp-config)#dns-server 192.168.240.200
- switch-gelb(dhcp-config)#office.xinux.org
- switch-gelb(dhcp-config)#ip dhcp pool dpool40
- switch-gelb(dhcp-config)#network 192.168.40.0 255.255.255.0
- switch-gelb(dhcp-config)#default-router 192.168.40.1
- switch-gelb(dhcp-config)#dns-server 192.168.240.200
- switch-gelb(dhcp-config)#domain-name labor.xinux.org
Dhcp Pools anzeigen
- switch-gelb#show ip dhcp pool
Pool dpool20 : Utilization mark (high/low) : 100 / 0 Subnet size (first/next) : 0 / 0 Total addresses : 254 Leased addresses : 2 Excluded addresses : 50 Pending event : none 1 subnet is currently in the pool : Current index IP address range Leased/Excluded/Total 192.168.20.53 192.168.20.1 - 192.168.20.254 2 / 50 / 254 Pool dpool30 : Utilization mark (high/low) : 100 / 0 Subnet size (first/next) : 0 / 0 Total addresses : 254 Leased addresses : 0 Excluded addresses : 50 Pending event : none 1 subnet is currently in the pool : Current index IP address range Leased/Excluded/Total 192.168.30.1 192.168.30.1 - 192.168.30.254 0 / 50 / 254 Pool dpool40 : Utilization mark (high/low) : 100 / 0 Subnet size (first/next) : 0 / 0 Total addresses : 254 Leased addresses : 0 Excluded addresses : 50 Pending event : none 1 subnet is currently in the pool : Current index IP address range Leased/Excluded/Total 192.168.40.1 192.168.40.1 - 192.168.40.254 0 / 50 / 254
Leases anzeigen
- switch-gelb#show ip dhcp binding
Bindings from all pools not associated with VRF: IP address Client-ID/ Lease expiration Type Hardware address/ User name 192.168.20.51 0160.eb69.962d.a5 Feb 02 2016 11:56 AM Automatic 192.168.20.52 0001.2e34.b06a Feb 02 2016 11:54 AM Automatic