cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
654
Views
0
Helpful
4
Replies

DHCP Server on Router

james_stickland
Level 1
Level 1

Hello, there is a big problem here. I have found that a cisco router with dhcp server enabled will not hand out IPs from a pool unless the router has an interface in the same subnet as the pool.

Anyone know how to overcome this? Is there a way to bind the dhcp server to a particular interface, despite the pool subnet being different than the subnet to which the interface IP is configured?

For example, I have ethernet0/0 with an IP address of 2.2.2.1

Clients attached to this broadcast domain are to receive an address in the 3.3.3.0/24 network, router address of 2.2.2.1

This has to be done, because Windows does not like holding onto a default route residing on a subnet different than the client address.

4 Replies 4

Richard Burts
Hall of Fame
Hall of Fame

James

Perhaps I have not understood something about your situation. But my experience of Windows is that if clients are given addresses in 3.3.3.0/24 then they need their default gateway to be in 3.3.3.0 and will not function correctly if the gateway is 2.2.2.1

If there is some aspect that I have not correctly understood then perhaps you can clarify for me?

HTH

Rick

HTH

Rick

Well, my isp gives me a few static IPs, so I have the route to them via an interface assigned a private IP - this is so I don't waste a routable IP for forwarding packets, when this procedure is taken care of by ARP. For example, here is the drawing

206.248.189.204/30----172.16.16.1-e0/0--Internet

The problem is, that the interface e0/0 will only hand out IPs via DHCP for the subnet it is on. Even if i set the pool to 206.248.189.204-207, the addresses are not handed out.

Normally, a host with a routable address would use 172.16.16.1 as the gateway. The hosts do a broadcast ARP asking for the mac of 172.16.16.1 and forward frames to that MAC. No routable IP needed when the hosts can use a gateway on a different subnet (but same layer 2 broadcast domain as in this case). Linux hosts can do this no problem, with a few route commands. Proper route commands work in windows, but dont stick on the interface real long, even if the route is tagged persistent. I have found this only works when Windows gets its ip via DHCP, but the router's DHCP server wont hand it out, because its IP is different than the pool's subnet. Linux and Windows DHCP servers work fine for this Argh!

Therefore, do you know a way for the Cisco DHCP server to hand out IPs from a pool that lies on a different subnet than the interface is configured for? Thanks.

I guess my last resort is to do DHCP relaying, to a different DHCP server on different vlan/subnet.

Later.

James

I still find your situation confusing. From what I think I understand of your explanation I believe that a more appropriate solution would be for the router/DHCP to assign addresses from private address space, and for the router to use the addresses given from the ISP in a network address translation pool and to translate the private addresses from the inside interface into the pool addresses for the outside interface.

HTH

Rick

HTH

Rick

well, im sure its more inappropriate if people do not do this, and actually waste a routable address! If this goes on frequently, there could be hundreds of thousands of addresses wasted from ipv4. ARP does the job, so should route, at least not on windows. The route flaps, unless its given via dhcp!

I will write an article on this.

Getting Started

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: