You are on page 1of 5

Marwadi University

Faculty of Engineering and Technology


Department of Information and Communication Technology
Subject: Computer Aim: Configure DHCP server.
Networks (01CT0503)
Experiment No: 09 Date:30-10-2023 Enrolment No: 92100133062

Aim: Configure DHCP server.

 Here, we have 5 PCs connected with one switch and switch is connected
with router.
 We are trying to perform DHCP (Dynamic Host Configuration Protocol)
to assign automatic IP address to all end devices connected with switch.

 The given figure shows connection between router and end devices.
 Here, we have connected GigabitEthernet 0/0/0 port of router with
GigabitEthernet 0/1 port of switch.
 We have connected all end devices with switch at ports FastEthernet 0/1
to FastEthernet 0/5.
 To perform DHCP, first we need to assign IP address to router which we
have given by using following commands :

enable
config t
Marwadi University
Faculty of Engineering and Technology
Department of Information and Communication Technology
Subject: Computer Aim: Configure DHCP server.
Networks (01CT0503)
Experiment No: 09 Date:30-10-2023 Enrolment No: 92100133062

int g0/0/0
ip add 10.0.0.1 255.0.0.0
no shut

 Explanation:

1. First command “enable” is used to switch from user mode to privilege


mode.
2. Second command “config t” is used to switch from privilege mode to
configuration mode.
3. Third command “int g0/0/0” is used to select port g0/0/0.
4. Fourth command “ip add” is used to give IP address to selected port.
5. Fifth command “no shut” is used to set that port high for transmission. If
not set then we will not be able to transmit or receive any data.

 After assigning IP address to router, we are now ready to implement


DHCP protocol. For that we have used following commands :

ip dhcp pool ICT


network 10.0.0.2 255.0.0.0
default route 10.0.0.1

 Explanation:

1. First command the "ip dhcp pool ICT" command is used to configure a
DHCP pool named "ICT".
2. The command "network 10.0.0.2 255.0.0.0" specifies the network IP
address and subnet mask for the DHCP pool. This indicates that the
DHCP pool will assign IP addresses from the 10.0.0.2/24 network.
3. The command "default-router 10.0.0.1" sets the default gateway (or
router) IP address for devices that receive IP addresses from this DHCP
pool.
Marwadi University
Faculty of Engineering and Technology
Department of Information and Communication Technology
Subject: Computer Aim: Configure DHCP server.
Networks (01CT0503)
Experiment No: 09 Date:30-10-2023 Enrolment No: 92100133062

 IP address assigned to PC0 using DHCP protocol.

 IP address assigned to PC2 using DHCP protocol.


Marwadi University
Faculty of Engineering and Technology
Department of Information and Communication Technology
Subject: Computer Aim: Configure DHCP server.
Networks (01CT0503)
Experiment No: 09 Date:30-10-2023 Enrolment No: 92100133062

 Changing IP configuration from DHCP to Static

 IP address assigned to PC3 using DHCP protocol.

 Here, we can see that if any end device is shifted from DHCP to static IP
Marwadi University
Faculty of Engineering and Technology
Department of Information and Communication Technology
Subject: Computer Aim: Configure DHCP server.
Networks (01CT0503)
Experiment No: 09 Date:30-10-2023 Enrolment No: 92100133062

allocation and any other device tries to connect through DHCP, the IP
address allocated to previous device will be shifted to new device. This is
because DHCP is dynamic routing protocol and because of that no IP
address is wasted at time of allocation.

Conclusion:

From this experiment, I learnt the usage of DHCP and how it differs from static IP
address allocation like for static, we have to assign IP address according to their network
but in DHCP, the IP addresses are allocated dynamically only by IP address (default
gateway address).
Also learnt new commands for configuring router for DHCP protocol.

You might also like