How to configure 4 and more than 4 DHCP server on a single router?

CCNA

In this tutorial, we will learn, how to make a router as multiple DHCP servers like in this case here I make 4 DHCP server on a single router and assign IP address on all the PC lying in the different network by a single router. To show this configuration we will use Cisco packet tracer software, and here we will make a lab to show you how to make a router as multiple DHCP servers. In this lab, we will use 1 router, 4 switches, and 8 computers. In this lab, all four switches present in a different network and each computer get their IP from the router according to their network. For complete this process, we have to create 4 DHCP pool on the router.

Also Read: How to configure a single router as a DHCP server?

single router as 4 and more dhcp server

In this lab, we will create different DHCP pool on a single router on its interfaces by using given below code according to its interface.

First of all, set hostname on router using these given below commands

Router>enable

Router#config t

Enter configuration commands,one per line. End with CNTL/Z

Router(config)#hostname R1

R1(config)#

 

Now on port fa0/0

Use this command on a FastEthernet0/0 port of the router to assign IP on port and make DHCP pool on it.

R1(config)#interface FastEthernet0/0

R1(config-if)#ip address 1.0.0.1 255.0.0.0

R1(config-if)#no shutdown

%LINK-5-CHANGED: Interface FastEthernet0/0, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/0, changed state to up

R1(config-if)#ip dhcp pool S1

R1(dhcp-config)#network 1.0.0.0 255.0.0.0

R1(dhcp-config)#default-router 1.0.0.1

R1(dhcp-config)#exit

 

Now on port fa0/1

R1(config)#interface FastEthernet0/1

R1(config-if)#ip address 2.0.0.1 255.0.0.0

R1(config-if)#no shutdown

%LINK-5-CHANGED: Interface FastEthernet0/1, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/1, changed state to up

R1(config-if)#ip dhcp pool S2

R1(dhcp-config)#network 2.0.0.0 255.0.0.0

R1(dhcp-config)#default-router 2.0.0.1

R1(dhcp-config)#exit

 

Now on port Ethernet0/0/0

R1(config)#interface Ethernet0/0/0

R1(config-if)#ip address 3.0.0.1 255.0.0.0

R1(config-if)#no shutdown

%LINK-5-CHANGED: Interface Ethernet0/0/0, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Ethernet0/0/0, changed state to up

R1(config-if)#ip dhcp pool S3

R1(dhcp-config)#network 3.0.0.0 255.0.0.0

R1(dhcp-config)#default-router 3.0.0.1

R1(dhcp-config)#exit

 

Now on port Ethernet0/0/1

R1(config)#interface Ethernet0/1/0

R1(config-if)#ip address 4.0.0.1 255.0.0.0

R1(config-if)#no shutdown

%LINK-5-CHANGED: Interface Ethernet0/1/0, changed state to up

%LINEPROTO-5-UPDOWN: Line protocol on Interface Ethernet0/1/0, changed state to up

R1(config-if)#ip dhcp pool S4

R1(dhcp-config)#network 4.0.0.0 255.0.0.0

R1(dhcp-config)#default-router 4.0.0.1

R1(dhcp-config)#exit

R1(config)#%DHCPD-4-PING_CONFLICT: DHCP address conflict: server pinged 1.0.0.1.

%DHCPD-4-PING_CONFLICT: DHCP address conflict: server pinged 2.0.0.1.

%DHCPD-4-PING_CONFLICT: DHCP address conflict: server pinged 3.0.0.1.

%DHCPD-4-PING_CONFLICT: DHCP address conflict: server pinged 4.0.0.1.

After that process, your router is able to provide IP address to the computers which are connected through the switches to the router.

 

Now to see all DHCP bound IP

Use below-given command

R1#show ip dhcp binding

Ip address Client-ID/ Lease expiration Type

Hardware address

1.0.0.2 00E0.F910.5DAB—Automatic

1.0.0.3 0060.7049.9126—Automatic

2.0.0.2 0060.3EC4.68C8—Automatic

2.0.0.3 00E0.A303.23D7—Automatic

3.0.0.2 0090.210E.92AB—Automatic

3.0.0.3 0000.0C33.D455—Automatic

4.0.0.2 00D0.FF47.55EB—Automatic

4.0.0.3 0001.C78E.AC98—Automatic

Now your router will act as a DHCP server and provide IP address to the all computers which is connected by router through a switch.

THAT’S IT

If you have any queries regarding this, you can be solved that by commenting on the post.

Leave a Reply