This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
dhcp [2024/03/14 21:45] 114.119.155.78 old revision restored (2023/11/03 14:09) |
dhcp [2024/03/14 22:03] 114.119.145.194 old revision restored (2022/09/26 07:42) |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | =====DHCP===== | + | DHCP |
- | ====Configuration==== | + | |
- | Below is the configuration for DHCP in Cisco' | + | |
- | + | ||
- | < | + | |
- | R1(dhcp-config)# | + | |
- | no ip dhcp use vrf connected | + | |
- | ip dhcp excluded-address 192.168.1.1 192.168.1.49 | + | |
- | ip dhcp excluded-address 172.16.0.1 | + | |
- | ip dhcp pool LAN # Define a pool | + | |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | lease 0 23 59 # Lease DAYS HRS MINS | + | |
- | </ | + | |
- | + | ||
- | ====DHCP Relay==== | + | |
- | Relays are configured with **'' | + | |
- | + | ||
- | The helper address is configured on the interface connected to the subnet which does not contain the DHCP server. | + | |
- | < | + | |
- | interface FastEthernet0/ | + | |
- | ip address 172.16.0.1 255.255.255.0 | + | |
- | ip helper-address 192.168.1.1 | + | |
- | | + | |
- | speed auto | + | |
- | end | + | |
- | + | ||
- | </ | + | |
- | + | ||
- | ====Show Commands==== | + | |
- | + | ||
- | ===View Leases=== | + | |
- | < | + | |
- | R1#sh ip dhcp binding | + | |
- | Bindings from all pools not associated with VRF: | + | |
- | IP address | + | |
- | Hardware address/ | + | |
- | User name | + | |
- | 172.16.0.2 | + | |
- | 3230.342e.3430.3930. | + | |
- | 2e30.3030.312d.4661. | + | |
- | 302f.31 | + | |
- | 192.168.1.50 | + | |
- | 3230.332e.3366.6461. | + | |
- | 2e30.3030.302d.4661. | + | |
- | 302f.30 | + | |
- | </ | + | |
- | + | ||
- | ===Server Statistics=== | + | |
- | < | + | |
- | R1#sh ip dhcp server statistics | + | |
- | Memory usage | + | |
- | Address pools 2 | + | |
- | Database agents | + | |
- | Automatic bindings | + | |
- | Manual bindings | + | |
- | Expired bindings | + | |
- | Malformed messages | + | |
- | Secure arp entries | + | |
- | + | ||
- | Message | + | |
- | BOOTREQUEST | + | |
- | DHCPDISCOVER | + | |
- | DHCPREQUEST | + | |
- | DHCPDECLINE | + | |
- | DHCPRELEASE | + | |
- | DHCPINFORM | + | |
- | + | ||
- | Message | + | |
- | BOOTREPLY | + | |
- | DHCPOFFER | + | |
- | DHCPACK | + | |
- | DHCPNAK | + | |
- | </ | + | |
- | + | ||
- | ===Pool Stats=== | + | |
- | Note that '' | + | |
- | < | + | |
- | R1#sh ip dhcp pool | + | |
- | + | ||
- | Pool LAN : | + | |
- | | + | |
- | | + | |
- | Total addresses | + | |
- | | + | |
- | | + | |
- | 1 subnet is currently in the pool : | + | |
- | | + | |
- | | + | |
- | </ | + |