Sei sulla pagina 1di 6

1) Console into Sw1.

Remove the existing ip default-gateway from the configurati


on.
2) Console into R1. Change the address on interface f0/0 to 192.168.4.1 255.255.
255.0
3) On R1, configure a DHCP pool using an IOS command. Name it Engineering.
4) On R1, configure the pool of addresses to be assigned to clients to be taken
from the 192.168.4.0 /24 network.
5) Configure R1 s DHCP service to assign the domain name, cisco.com, to each DHCP
client.
6) On R1, have the DHCP server assign the default gateway of 192.168.4.1 to the
clients as part of the lease.
7) On R1, have the DHCP service list 4.2.2.1 as the DNS server for all hosts on
the Engineering subnet to use.
8) By default, the DHCP service on your router will lease the address to clients
for one day. Change this to 5 days on R1.
9) Pretend that the users on the engineering subnet all shared files with each o
ther on an FTP server with the address 192.168.4.5. You don t want the DHCP server
to accidentally assign this address also to a user, so exclude it from the pool
.
10) By default, the DHCP service on a Cisco router is disabled. Enable DHCP on R
1.
11) Console into Sw1. Configure the VLAN 1 interface to get its IP address from
the DHCP server.
12) On Sw1, shut down the VLAN 1 interface, wait for a status message, and then
re-enable it.
13) On Sw1, verify that VLAN 1 has been given a new address.
14) On Sw1, verify that the DHCP server has assigned the domain name, cisco.com.

15) On Sw1, verify that the DHCP server has assigned the DNS server address: 4.2
.2.1
16) On Sw1, verify that the DHCP server has assigned it a new default gateway ad
dress: 192.168.4.1
17) Console into R1. Use a show command to verify the range of the DHCP pool you
previously configured.
18) On R1, use a show command to verify DHCP server statistics.
19) You have finished the lab.

Step 1 : Console into Sw1. Remove the existing ip default-gateway from the confi
guration.
Action:
sw1> enable
sw1# config t
sw1(config)# no ip default-gateway
sw1(config)#

Result:

Step 2 : Console into R1. Change the address on interface f0/0 to 192.168.4.1 25
5.255.255.0
Action:
r1> enable
r1# config t
r1(config)# interface f0/0
r1(config-if)# ip address 192.168.4.1 255.255.255.0
r1(config-if)#

Result:
Anytime you see a device blinking, it is a reminder to console into a new device
.
Explanation:
If you are prompted for a password, enter cisco for user mode and sanfran for pr
ivileged mode.
Step 3 : On R1, configure a DHCP pool using an IOS command. Name it Engineering.
Action:
r1(config-if)# exit
r1(config)# ip dhcp pool Engineering
r1(dhcp-config)#

Result:
In the courseware, the Cisco SDM is discussed as one method to configure a Cisco
router as a DHCP server. However, the DHCP service can just as easily be config
ured at the command line. For screenshots of the method via SDM, you can still r
eview what is in the book, but here we will focus on the more direct approach.
Explanation:
Here is the scenario for this lab. The engineers in your department are all on t
he same subnet and are connected to Sw1. Rather than purchasing a separate DHCP
server to assign IP addresses to the engineers, you have decided to configure R1
as their DHCP server.
Step 4 : On R1, configure the pool of addresses to be assigned to clients to be
taken from the 192.168.4.0 /24 network.
Action:
r1(dhcp-config)# network 192.168.4.0 /24
r1(dhcp-config)#
Result:
The address on f0/0 is 192.168.4.1 and on the same subnet as your engineers.
Explanation:
This command allows the first engineer to receive the IP address 192.168.4.2, th
e second to receive 192.168.4.3, the third to receive 192.168.4.4, and so on. Th
e router is smart enough to know not to give out the .1 address, because it is a
lready using it.
Step 5 : Configure R1 s DHCP service to assign the domain name, cisco.com, to each
DHCP client.
Action:
r1(dhcp-config)# domain-name cisco.com
r1(dhcp-config)#

Result:
Explanation:
In addition to an IP address and subnet mask, a DHCP server can also supply the
client with other parameters such as the domain name, default gateway, DNS serve
r address, etc., when the lease is given.
Step 6 : On R1, have the DHCP server assign the default gateway of 192.168.4.1 t
o the clients as part of the lease.
Action:
r1(dhcp-config)# default-router 192.168.4.1
r1(dhcp-config)#

Result:
192.168.4.1 is R1. The engineers will automatically send any packets that are no
t on the local network to R1 to be routed.
Explanation:
Gateway is an older term for router. Therefore, the default gateway is actually
the default router to go to when packets have destinations that are not local.
Step 7 : On R1, have the DHCP service list 4.2.2.1 as the DNS server for all hos
ts on the Engineering subnet to use.
Action:
r1(dhcp-config)# dns-server 4.2.2.1
r1(dhcp-config)#

Result:
Explanation:
DNS translates domain names into IP addresses. The address shown here is only an
example.

Step 8 : By default, the DHCP service on your router will lease the address to c
lients for one day. Change this to 5 days on R1.
Action:
r1(dhcp-config)# lease 5
r1(dhcp-config)#

Result:
Explanation:
Once the lease expires, the client can request a new lease.
Step 9 : Pretend that the users on the engineering subnet all shared files with
each other on an FTP server with the address 192.168.4.5. You don t want the DHCP
server to accidentally assign this address also to a user, so exclude it from th
e pool.
Action:
r1(dhcp-config)# exit
r1(config)# ip dhcp excluded-address 192.168.4.5
r1(config)#

Result:
This command is done from global configuration mode.
Explanation:
With this command, the .5 address will be skipped when leases are handed out.
Step 10 : By default, the DHCP service on a Cisco router is disabled. Enable DHC
P on R1.
Action:
r1(config)# service dhcp
r1(config)#

Result:
This command is also done from global configuration mode.
Explanation:
You have configured the DHCP parameters in the previous steps, but the router wa
s not acting as a DCHP server until now.
Step 11 : Console into Sw1. Configure the VLAN 1 interface to get its IP address
from the DHCP server.
Action:
sw1> enable
sw1# config t
sw1(config)# interface vlan 1
sw1(config-if)# ip address dhcp
sw1(config-if)#

Result:
Explanation:
Since this is a lab and you really don t have engineers attached to Sw1, you can t
est your configuration by making the switch itself a DCHP client. Prior to this
step, Sw1 was configured with the IP address of 10.4.1.2 and a default gateway o
f 10.4.1.1.
Step 12 : On Sw1, shut down the VLAN 1 interface, wait for a status message, and
then re-enable it.
Action:
sw1(config-if)# shut (WAIT FOR THE STATUS MESSAGE)
sw1(config-if)# no shut

Result:
Explanation:
By shutting down the interface and bringing it back online, you trigger the DHCP
request. After you have entered the no shut command, wait about 10 seconds befo
re proceeding to the next step.
Step 13 : On Sw1, verify that VLAN 1 has been given a new address.
Action:
sw1(config-if)# end
sw1# show ip interface brief
sw1#

Result:
Explanation:
You should find that VLAN 1 now has the address 192.168.4.2, since it would be t
he first available address in the DHCP pool.
Step 14 : On Sw1, verify that the DHCP server has assigned the domain name, cisc
o.com.
Action:
sw1# show ip domain
sw1#

Result:
You should see: cisco.com
Step 15 : On Sw1, verify that the DHCP server has assigned the DNS server addres
s: 4.2.2.1
Action:
sw1# show ip name-server
sw1#

Result:
You should see: 4.2.2.1
Step 16 : On Sw1, verify that the DHCP server has assigned it a new default gate
way address: 192.168.4.1
Action:
sw1# show ip default-gateway
sw1#

Result:
You should see: 192.168.4.1
Step 17 : Console into R1. Use a show command to verify the range of the DHCP po
ol you previously configured.
Action:
r1(config)# end
r1# show ip dhcp pool
r1#

Result:
Anytime you see a device blinking, it is a reminder to console into a new device
.
Explanation:
Near the bottom of the output you can see how many leases have been given out, t
he range, and the next IP address to be assigned.
Step 18 : On R1, use a show command to verify DHCP server statistics.
Action:
r1# show ip dhcp server statistics
r1#

Result:
Explanation:
This allows you to see counts on the underlying DHCP packets that are being exch
anged like the DHCPDISCOVER, DHCPOFFER, and DHCPREQUEST messages.
Step 19 : You have finished the lab.