Configure Multiplayer/Layer 3 Switch as DHCP Server
This post is
about how to configure Layer 3 Device as a DHCP server or how to configure DHCP
server on multilayer device. So that switch can provide IP configuration in
network.
We have a Layer three
switch and we will be going to configure DHCP server on this switch. first of all,
we need to configure IP address on VLAN 1 because by default all switch ports
are member of VLAN 1 so we don’t need to create VLANs. Configure the following
IP address for VLAN 1.
IP address – 192.168.1.1
Subnet mask - 255.255.255.0
Connect switch with any computer by console cable and access switch. (putty, hyper terminal etc)
Step: 1 Configuring IP address for VLAN 1/Switch Port.
Switch>enable
Switch#configure terminal
Switch(config)#
Switch(config)#interface vlan 1
Switch(config-if)#ip address
192.168.1.1 255.255.255.0
Switch(config-if)#no shutdown
Switch(config-if)#exit
We have configured the IP address on switch now we can configure
DHCP server on switch. We care going to configure DHCP server with going
configuration.
Network – 192.168.1.0 (255.255.255.0)
IP address Range - 192.168.1.2 to 10.255.255.255.0
DNS Server - 8.8.8.8
Follow the Step 2
Step:2 Creating DHCP Pool with Default getaway and DNS
server.
Switch(config)#
Switch(config)#ip dhcp pool sys
Switch(dhcp-config)#network 192.168.1.0
Switch(dhcp-config)#default-router 192.168.1.1
Switch(dhcp-config)#dns-server 8.8.8.8
Switch(dhcp-config)#exit
Exclude the IP address or IP Range that we don’t want to
provide in network like switch VLAN IP 192.168.1.1
To exclude the IP address or IP range run the following
command.
Switch(config)#ip dhcp excluded-address 192.168.1.1
Switch(config)#exit
Step:3 Save the configuration on startup.
Switch#write
Now all done, our switch is ready to provide IP
configuration in Network.
No comments:
Post a Comment