notepad

Posts tagged “dhcp ipv4

ipv4 DHCP

dhcp topology

IP DHCP

R2(config)#ip dhcp pool OUR-Pool
R2(dhcp-config)#network 10.0.0.0 255.255.255.0
R2(dhcp-config)#default-router 10.0.0.2
R2(dhcp-config)#dns-server 8.8.8.8
R2(dhcp-config)#lease 2
R2(dhcp-config)#exit
R2(config)#ip dhcp excluded-address 10.0.0.1 10.0.0.24
R2(config)#end

R2#show ip dhcp pool

Pool OUR-Pool :
Utilization mark (high/low)    : 100 / 0
Subnet size (first/next)       : 0 / 0
Total addresses                : 254
Leased addresses               : 0
Pending event                  : none
1 subnet is currently in the pool :
Current index        IP address range                    Leased addresses
10.0.0.1             10.0.0.1         – 10.0.0.254        0

==============================================================================================

R1(config)#int f0/0
R1(config-if)#ip address dhcp
R1(config-if)#end
R1#
*Mar  1 00:07:16.691: %SYS-5-CONFIG_I: Configured from console by console
R1#
*Mar  1 00:07:24.779: %DHCP-6-ADDRESS_ASSIGN: Interface FastEthernet0/0 assigned DHCP address 10.0.0.25, mask 255.255.255.0, hostname R1

R1#show dhcp server  
DHCP server: ANY (255.255.255.255)
Leases:   1
Offers:   1      Requests: 1     Acks : 1     Naks: 0
Declines: 0      Releases: 0     Query: 0     Bad: 0
DNS0:   8.8.8.8,   DNS1:  0.0.0.0
Subnet: 255.255.255.0

R1#show ip route | begin Gateway
Gateway of last resort is 10.0.0.2 to network 0.0.0.0

10.0.0.0/24 is subnetted, 1 subnets
C       10.0.0.0 is directly connected, FastEthernet0/0
S*   0.0.0.0/0 [254/0] via 10.0.0.2

====================================================================================================

R2#show ip dhcp binding
Bindings from all pools not associated with VRF:
IP address          Client-ID/              Lease expiration        Type
Hardware address/
User name
10.0.0.25           0063.6973.636f.2d63.    Mar 03 2002 01:22 AM    Automatic
3030.312e.3231.6238.
2e30.3030.302d.4661.
302f.30

PC :

PC1>
PC1> ip dhcp
DDORA IP 10.0.0.26/24 GW 10.0.0.2

PC1> ping 10.0.0.2
84 bytes from 10.0.0.2 icmp_seq=1 ttl=255 time=19.001 ms
84 bytes from 10.0.0.2 icmp_seq=2 ttl=255 time=29.002 ms
84 bytes from 10.0.0.2 icmp_seq=3 ttl=255 time=29.002 ms
84 bytes from 10.0.0.2 icmp_seq=4 ttl=255 time=29.002 ms
84 bytes from 10.0.0.2 icmp_seq=5 ttl=255 time=29.002 ms