3

I have a D-Link DGL-4500 and I've been using that for a long time as my DHCP server. I now have a Windows Server 2008 R2 machine plugged into it and I have set it up as a DHCP server.

I don't have 2 NICs on my server machine, so I still wanted to use my router as the main hub where all of my machines connect. The only thing I don't want the router to be anymore is the DHCP server, but I still enjoy it as a firewall.

Is there a way I can use plain old port forwarding or something similar in my router to forward DHCP requests from computers connected to it to my Windows server? My router doesn't have a "DHCP Relay" feature that I can see, I only have the ability to turn the DHCP server on my router on or off.

Help is greatly appreciated!

user48838
  • 7,393
  • 2
  • 17
  • 14
void.pointer
  • 505
  • 2
  • 8
  • 16

3 Answers3

4

If the NAT router and the DHCP server are both on the same LAN, just turn off the DHCP functionality on the NAT router. The DHCP server will then take over for the LAN.

user48838
  • 7,393
  • 2
  • 17
  • 14
  • Oops... And also update the gateway/DNS accordingly as Ben Pilbrow has pointed out on the DHCP server configuration. – user48838 Aug 11 '11 at 13:05
  • When my PC makes a DHCP request, how does my router know to send that request to my Windows DHCP server? I don't understand the logic of how this works. – void.pointer Aug 11 '11 at 18:10
  • The initial DHCP "discovery" occurs at layer 2 (the NIC level) where an ethernet (not IP) broadcast takes place to negotiate the DHCP server. The request is sent out to all devices on the LAN in order to determine the DHCP server (if there is one). – user48838 Aug 12 '11 at 05:23
2

Why not just turn off DHCP on the router and set the appropriate options in the Windows DHCP server?

In the Windows DHCP scope, set the gateway as your router and also DNS if you want.

Ben Pilbrow
  • 11,995
  • 5
  • 35
  • 57
-1

As far as I know it is impossible to route broadcast IP packets. And DHCP requests are broadcasts.

But if the server is in the same network then you can just disable the DHCP on the router and enable it on the server. This works because all machines in the network will receive the broadcast and answer accordingly (or not if they are no DHCP server).

mailq
  • 16,882
  • 2
  • 36
  • 66