05-14-2022 01:36 PM
I am a beginner and I'm working with this packet tracer file, trying to practice DHCP and ip routing. These are very confusing topics to me so if anyone could help me figure out how to set this up and explain how it works that would be great. I attached the pkt file that I'm using.
Solved! Go to Solution.
05-15-2022 04:47 PM
Yes. And don’t forget the static route to get to the 172.16.9.0 network on R1
05-15-2022 04:59 PM
So I put "ip route 192.16.9.0 255.255.255.0 172.16.8.2" on R1, and then on R2 I put "ip route 10.19.8.0 255.255.255.0 g0/0/0" and I'm still unable to ping. Could there be something wrong somewhere else? Do I need to setup DHCP before the pings work or should they just work now?
05-15-2022 05:06 PM - edited 05-15-2022 05:07 PM
I think you meant 172.16.9.0 255.255.255.0. Also make sure the sub interfaces have the helper address under each sub interface to reach the DHCP server.
interface GigabitEthernet0/0/1.10
description VLAN 10
encapsulation dot1Q 10
ip address 10.19.8.1 255.255.255.192
ip helper-address 172.16.9.9
ipv6 address FE80::1 link-local
ipv6 address 2001:DB8:ACAD:A::1/64
What are you pinging? From where to where? Make sure your clients are getting an IP address or they wont ping.
-David
05-15-2022 05:26 PM
Hm this is weird, I did all of that and still can't get pings to work. Here is what I get from the show ip route command, do you see anything weird in here?
R1 -
"Gateway of last resort is not set
10.0.0.0/8 is variably subnetted, 6 subnets, 4 masks
C 10.19.8.0/26 is directly connected, GigabitEthernet0/0/1.10
L 10.19.8.1/32 is directly connected, GigabitEthernet0/0/1.10
C 10.19.8.64/27 is directly connected, GigabitEthernet0/0/1.20
L 10.19.8.65/32 is directly connected, GigabitEthernet0/0/1.20
C 10.19.8.96/29 is directly connected, GigabitEthernet0/0/1.30
L 10.19.8.97/32 is directly connected, GigabitEthernet0/0/1.30
172.16.0.0/16 is variably subnetted, 3 subnets, 3 masks
C 172.16.8.0/30 is directly connected, GigabitEthernet0/0/0
L 172.16.8.1/32 is directly connected, GigabitEthernet0/0/0
S 172.16.9.0/24 [1/0] via 172.16.8.2"
R2:
"Gateway of last resort is not set
10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
R 10.0.0.0/8 [120/1] via 172.16.8.1, 00:00:26, GigabitEthernet0/0/0
S 10.19.8.0/24 is directly connected, GigabitEthernet0/0/0
172.16.0.0/16 is variably subnetted, 4 subnets, 3 masks
C 172.16.8.0/30 is directly connected, GigabitEthernet0/0/0
L 172.16.8.2/32 is directly connected, GigabitEthernet0/0/0
C 172.16.9.0/24 is directly connected, GigabitEthernet0/0/1
L 172.16.9.1/32 is directly connected, GigabitEthernet0/0/1"
05-15-2022 05:35 PM
It looks like you have RIP running on R2 but not R1. I would take that off
no router rip
It advertises classful networks but you have the 10 network subnetted out. Do your clients have IP addresses from DHCP?
-David
05-15-2022 05:45 PM - edited 05-15-2022 06:00 PM
I did no router rip and still not working. The PCs are set to use DHCP but right now it's not working so it says it's using APIPA.
edit: nvm it works now
05-15-2022 05:52 PM - edited 05-15-2022 06:06 PM
I excluded the first 10 addresses earlier because i thought you had to do that, not exactly sure what that does though. I just undid it and it still doesn't work anyway.
edit: nvm it works now
05-15-2022 05:59 PM - edited 05-15-2022 06:00 PM
nevermind I got it to work, I must've messed something up in that packer tracer earlier so I just opened a fresh one and put in the routes and it works. One more thing, how would you set up DHCP using a DHCP Pool instead of just putting the helper addresses in?
05-15-2022 06:21 PM - edited 05-15-2022 06:26 PM
So say you wanted a dhcp pool of a /24 network with the first 10 addresses excluded from being given out, it would look like this
ip dhcp pool test
ip dhcp excluded-address 192.168.1.1 192.168.1.10 <-- this is the first 10 noted. This is a range. It will use the first and last address and everything in between and not give it out. You can create multiple excluded address ranges. This is done in GLOBAL config before you create the DHCP pool for each network you need to excluded addresses for. Then you go into DHCP configuration mode.
network 192.168.1.0 /24 (some IOS versions may not take / notation and you will have to write out the mask)
domain-name cisco.com
dns-server 192.168.1.5
default-router 192.168.1.1 <- default gateway clients will use to reach other networks. usually the interface IP of the router the clients use where you put the IP helper address
lease infinite
Some of these commands are optional. At a minimum I would configure the commands in bold. Just playing with the settings will help you learns the features. YOU would need one for each network. So if you wanted a DHCP pool for each of your sub interfaces you need 3 DHCP pools to hand them out.
Here is some CISCO documentation as well:
-David
05-15-2022 06:43 PM
I would use R2 to create the pools right?
05-15-2022 06:48 PM
I was going to include that in my original post. No you create the pools on the router with the hosts default gateways. So R1 would get 3 pools for the 10.19.8.0 network with their respective subnets. If hosts off of R2 need a DHCP pool then you would create theirs on R2. I created 1 DHCP pool for the g0/0/1.10 subinterface and shut down the link to R2. Then I did a release/renew on the client PC-PT Sales-A client and it pulled an IP from the pool I created.
You can verify with the show ip dhcp binding on R1 (or whatever router the pool is on)
ip dhcp excluded-address 10.19.8.1 10.19.8.10
!
ip dhcp pool test
network 10.19.8.0 255.255.255.192
default-router 10.19.8.1
!
Here is one pool I made for the first subnet on R1.
-David
05-15-2022 07:26 PM
When I set up that first one I got an error that said "%DHCPD-4-PING_CONFLICT: DHCP address conflict: server pinged 10.19.8.1." Can I just ignore that or is something wrong?
05-15-2022 07:34 PM
It means it pinged and found that address before it gave it out which means it’s available in the pool? Did you configure excluded addresses before creating the pool?
That address is the sunbInterface IP. Refer to my example above. You have to excluded addresses you don’t want handed out to include those already in use. This is don’t in global config mode. Then you create the dhcp pool also showed above
05-15-2022 07:46 PM
Ah yeah I forgot to do the excluded addresses. Just put that in
05-15-2022 07:58 PM
That’s fine. It’s not required.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide