07-09-2014 06:16 AM - edited 03-07-2019 07:59 PM
Hello,
I'm trying to build a typology similar to my work in GNS3, I'm using routers with the NM-16ESW module for 16 switch ports. Anyway I'm trying to get the host on the VLAN 90 switch an IP address via DHCP but it's having none of it. Core 1 and 2 are using HSRP for all our VLANs, I though the best way to add a DHCP server using a router would be to add it to both cores and using /30 subnets and advertise into OSPF and add the ip-helper address to the VLANs on each core. Someone did suggest making the 2 ports for the DHCP server a port channel, but I wasn't sure how I woudl configure this on the to cores.
Host 1
no ip routing
!
interface FastEthernet0/0
ip address dhcp
no ip route-cache
duplex auto
speed auto
90-Switch (layer 2)
no ip routing
!
interface FastEthernet1/0
Description Host 1
switchport access vlan 90
duplex full
speed 100
!
interface FastEthernet1/14
switchport trunk native vlan 23
switchport trunk allowed vlan 1,23,90,1002-1005
switchport mode trunk
duplex full
speed 100
!
interface FastEthernet1/15
switchport trunk native vlan 23
switchport trunk allowed vlan 1,23,90,1002-1005
switchport mode trunk
duplex full
speed 100
!
interface Vlan1
no ip address
no ip route-cache
shutdown
!
interface Vlan23
ip address 192.168.23.90 255.255.255.0
Core1
interface Port-channel1
switchport mode trunk
!
interface FastEthernet1/0
switchport mode trunk
duplex full
speed 100
channel-group 1 mode on
!
interface FastEthernet1/1
switchport mode trunk
duplex full
speed 100
channel-group 1 mode on
interface FastEthernet1/4
description DHCP Server
no switchport
ip address 192.168.41.2 255.255.255.252
duplex full
speed 100
interface FastEthernet1/13
switchport trunk native vlan 23
switchport trunk allowed vlan 1,2,23,100,1002-1005
switchport mode trunk
duplex full
speed 100
!
interface FastEthernet1/15
switchport trunk native vlan 23
switchport trunk allowed vlan 1,2,23,90,1002-1005
switchport mode trunk
duplex full
speed 100
!
interface Vlan1
no ip address
shutdown
!
interface Vlan2
ip address 128.101.10.69 255.255.0.0
standby 2 ip 128.101.10.70
standby 2 preempt
!
interface Vlan20
ip address 192.168.20.253 255.255.255.0
standby 20 ip 192.168.20.254
standby 20 preempt
!
interface Vlan21
ip address 192.168.21.253 255.255.255.0
ip helper-address 192.168.21.1
standby 21 ip 192.168.21.254
standby 21 preempt
!
interface Vlan23
ip address 192.168.23.253 255.255.255.0
standby 23 ip 192.168.23.254
standby 23 preempt
!
interface Vlan30
ip address 192.168.30.253 255.255.255.0
standby 30 ip 192.168.30.254
standby 30 preempt
!
interface Vlan40
ip address 192.168.40.253 255.255.255.0
standby 40 ip 192.168.40.254
standby 40 preempt
!
interface Vlan50
ip address 192.168.50.253 255.255.255.0
standby 50 ip 192.168.50.254
standby 50 preempt
!
interface Vlan60
ip address 192.168.60.253 255.255.255.0
standby 60 ip 192.168.60.254
standby 60 preempt
!
interface Vlan70
ip address 192.168.70.253 255.255.255.0
standby 70 ip 192.168.70.254
standby 70 preempt
!
interface Vlan80
ip address 192.168.80.253 255.255.255.0
standby 80 ip 192.168.80.254
standby 80 preempt
!
interface Vlan90
ip address 192.168.90.253 255.255.255.0
ip helper-address 192.168.41.1
standby 90 ip 192.168.90.254
standby 90 preempt
!
interface Vlan100
ip address 192.168.100.253 255.255.255.0
ip helper-address 192.168.41.1
standby 100 ip 192.168.100.254
standby 100 preempt
!
router ospf 1
router-id 1.1.1.1
log-adjacency-changes
network 192.168.41.0 0.0.0.3 area 0
network 192.168.90.0 0.0.0.255 area 0
network 192.168.100.0 0.0.0.255 area 0
Core 2
interface Port-channel1
switchport mode trunk
!
interface FastEthernet1/0
switchport mode trunk
duplex full
speed 100
channel-group 1 mode on
!
interface FastEthernet1/1
switchport mode trunk
duplex full
speed 100
channel-group 1 mode on
!
interface FastEthernet1/4
description DHCP Server
no switchport
ip address 192.168.41.6 255.255.255.252
duplex full
speed 100
!
interface FastEthernet1/14
switchport trunk native vlan 23
switchport trunk allowed vlan 1,2,23,90,1002-1005
switchport mode trunk
duplex full
speed 100
!
interface FastEthernet1/15
switchport trunk native vlan 23
switchport trunk allowed vlan 1,2,23,100,1002-1005
switchport mode trunk
duplex full
speed 100
interface Vlan2
ip address 128.101.10.68 255.255.0.0
standby 2 ip 128.101.10.70
standby 2 priority 109
standby 2 preempt
!
interface Vlan20
ip address 192.168.20.252 255.255.255.0
standby 20 ip 192.168.20.254
standby 20 priority 109
standby 20 preempt
!
interface Vlan21
ip address 192.168.21.252 255.255.255.0
standby 21 ip 192.168.21.254
standby 21 priority 109
standby 21 preempt
!
interface Vlan23
ip address 192.168.23.252 255.255.255.0
standby 23 ip 192.168.23.254
standby 23 priority 109
standby 23 preempt
!
interface Vlan30
ip address 192.168.30.252 255.255.255.0
standby 30 ip 192.168.30.254
standby 30 priority 109
standby 30 preempt
!
interface Vlan40
ip address 192.168.40.252 255.255.255.0
standby 40 ip 192.168.40.254
standby 40 priority 109
standby 40 preempt
!
interface Vlan50
ip address 192.168.50.252 255.255.255.0
standby 50 ip 192.168.50.254
standby 50 priority 109
standby 50 preempt
!
interface Vlan60
ip address 192.168.60.252 255.255.255.0
standby 60 ip 192.168.60.254
standby 60 priority 109
standby 60 preempt
!
interface Vlan70
ip address 192.168.70.252 255.255.255.0
standby 70 ip 192.168.70.254
standby 70 priority 109
standby 70 preempt
!
interface Vlan80
ip address 192.168.80.252 255.255.255.0
standby 80 ip 192.168.80.254
standby 80 priority 109
standby 80 preempt
!
interface Vlan90
ip address 192.168.90.252 255.255.255.0
ip helper-address 192.168.41.5
standby 90 ip 192.168.90.254
standby 90 priority 109
standby 90 preempt
!
interface Vlan100
ip address 192.168.100.252 255.255.255.0
ip helper-address 192.168.41.5
standby 100 ip 192.168.100.254
standby 100 priority 109
standby 100 preempt
!
router ospf 1
router-id 2.2.2.2
log-adjacency-changes
network 192.168.41.4 0.0.0.3 area 0
network 192.168.90.0 0.0.0.255 area 0
network 192.168.100.0 0.0.0.255 area 0
On the host 1 if I run a "shut" , "no shut" on fa 0/0 and run DHCP debug commands on the DHCP server I get this:
*Mar 1 00:36:19.915: DHCPD: Sending notification of DISCOVER:
*Mar 1 00:36:19.915: DHCPD: htype 1 chaddr cc0a.3714.0000
*Mar 1 00:36:19.919: DHCPD: remote id 020a0000c0a8290100000000
*Mar 1 00:36:19.919: DHCPD: circuit id 00000000
*Mar 1 00:36:19.919: DHCPD: DHCPDISCOVER received from client 0063.6973.636f.2d63.6330.612e.3337.3134.2e30.3030.302d.4661.302f.30 on interface FastEthernet0/0.
*Mar 1 00:36:19.919: DHCPD: Seeing if there is an internally specified pool class:
*Mar 1 00:36:19.919: DHCPD: htype 1 chaddr cc0a.3714.0000
*Mar 1 00:36:19.919: DHCPD: remote id 020a0000c0a8290100000000
*Mar 1 00:36:19.919: DHCPD: circuit id 00000000
*Mar 1 00:36:19.919: DHCPD: there is no address pool for 192.168.41.1.
*Mar 1 00:36:19.935: DHCPD: Sending notification of DISCOVER:
*Mar 1 00:36:19.935: DHCPD: htype 1 chaddr cc0a.3714.0000
*Mar 1 00:36:19.935: DHCPD: remote id 020a0000c0a8290501000000
*Mar 1 00:36:19.935: DHCPD: circuit id 00000000
*Mar 1 00:36:19.935: DHCPD: DHCPDISCOVER received from client 0063.6973.636f.2d63.6330.612e.3337.3134.2e30.3030.302d.4661.302f.30 on interface FastEthernet0/1.
*Mar 1 00:36:19.935: DHCPD: Seeing if there is an internally specified pool class:
*Mar 1 00:36:19.935: DHCPD: htype 1 chaddr cc0a.3714.0000
*Mar 1 00:36:19.935: DHCPD: remote id 020a0000c0a8290501000000
*Mar 1 00:36:19.935: DHCPD: circuit id 00000000
*Mar 1 00:36:19.935: DHCPD: there is no address pool for 192.168.41.5.
Thanks
07-09-2014 08:48 AM
Can you show the configuration of the DHCP server router?
07-10-2014 12:25 AM
Here it is:
ip dhcp pool VLAN90
network 192.168.90.0 255.255.255.0
default-router 192.168.90.254
!
ip dhcp pool VLAN100
network 192.168.100.0 255.255.255.0
default-router 192.168.90.254
!
interface FastEthernet0/0
ip address 192.168.41.1 255.255.255.252
duplex auto
speed auto
!
interface FastEthernet0/1
ip address 192.168.41.5 255.255.255.252
duplex auto
speed auto
!
router ospf 1
log-adjacency-changes
network 192.168.41.0 0.0.0.3 area 0
network 192.168.41.4 0.0.0.3 area 0
07-11-2014 03:16 AM
Just wondered if you had any ideas?
07-11-2014 03:33 AM
Nothing is jumping out at me to be honest! What happens if you try and create a reservation using client-identifier?
07-11-2014 11:39 AM
Not tried that before, how do I do that?
Something like this?
Host1#sh int fa 0/0
FastEthernet0/0 is up, line protocol is up
Hardware is AmdFE, address is cc0a.1d4c.0000 (bia cc0a.1d4c.0000)
Host1:
ip dhcp pool VLAN90
network 192.168.90.0 255.255.255.0
default-router 192.168.90.254
ip dhcp pool host1
host 192.168.90.123 255.255.255.0
client-identifier cc0a.1d4c.0000
client-name host1
That mac address didn't appear on the DHCP debug though.
07-11-2014 12:18 PM
That is correct. Just something I did notice, you don't have any ip dhcp excluded addresses configured on the DHCP router. Is this just missing from your output or are they not configured? You would need to exclude any addresses from the pool that have already been assigned.
07-14-2014 05:49 AM
Yes excluded IPs are included as part of the DHCP pool, sorry I should of mentioned.
It's as if the DHCP discovers are not reaching the DHCP server.
07-14-2014 07:06 AM
No problem.
Would it be possible for you to disable HSRP and drop all the connections from Core 1 except to the DHCP server and from the DHCP server to your root primary?
07-17-2014 03:29 AM
Is it normal to add a DHCP server this way using a router, should I be using a trunk from the router to the 2 cores instead?
07-16-2014 01:44 PM
Same issue I'm afraid. I just added a router on Core 2 on vlan 90 and made it a DHCP server and added a scope for the 192.168.90.x subnet and it was ok. It just seems the IP helper address isn't forwarding the offers.
I wondered if the host 1 could reach the DHCP router so I added a static IP and it can ping 192.168.41.1 and 192.168.41.5.
07-18-2014 02:09 AM
Hi.
I just lab'd this in GNS3 and managed to get it working. I wasn't able to replicate your topology fully as my laptop is not powerful enough! I used two routers (DHCP server and host) and a single "multilayer" switch, and I didn't use OSPF.
On the DHCP server, disable IP routing, or as in your topology, make sure there is a route back to the .90 vlan on your DHCP server router.
On the link between the host router and the layer 2 switch, I changed to a trunk on the layer 2 switch, and a sub-interface with the encapsulation set to vlan 90:
int fa0/0.1
encapsulation dot1q 90
ip address dhcp
speed 100
duplex full
no shut
Can you give that a try and let me know?
07-18-2014 04:02 AM
This is for the host?
int fa0/0.1
encapsulation dot1q 90
ip address dhcp
speed 100
duplex full
no shut
What happened when you tried the lab as layer 3 and not layer 2?
07-18-2014 04:11 AM
Yep, the sub-interface should be configured on the host router.
The switch was set up as a layer 2 trunk (for the host router) and layer 3 interface (for the DHCP router) as well as the SVI for vlan 90.
It made me think (from an ROAS perspective) that the interface on the host router would be considered to be in the native vlan (1). This would not match the vlan 90 configuration.
07-18-2014 04:41 AM
Hello
What model is the layer2 switch?
also try this:
host
int fa1/0
ip address dhcp client-id fastEthernet 1/0
exit
ip route 0.0.0.0 0.0.0.0 dhcp
renew dhcp fa1/0
res
Paul
Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: