Discussion Locked

DHCP in Windows 2000

0 helpful
4 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

I have one w2k advanced server and 50 w2k professional clients.I divided my 50 clients into 3 labs.15 clients in sales lab,20 clients in marketing lab,15 clients in accounts lab.Then i created 3 scopes in DHCP.
Sales Scope: 192.168.100.10 to 192.168.100.25
Marketing Scope:192.168.100.30 to 192.168.100.50
Accounts Scope:192.168.100.60 to 192.168.100.75
When my clients communicate with dhcp they gets IP address.If sales clients communicate with dhcp they get ip from sales,marketing gets ip from marketing scope,accounts clients get ip from accounts scope.How i do it or how the DHCP knows which is sales,marketing,accounts clients.
Anurag.

4 replies

by shortbus

First off, there's a rule you have to know.

1) A DHCP server can only have 1 scope per subnet
2) DHCP server hands out addresses from scope that matches the subnet of the origin of the DHCPdiscover message.

Knowing that, you're existing ranges are invalid unless you want to setup 50 reservations out of a single scope.

Based on your scopes, I figured that you wanted the smallest possible scope size for you networks. That's OK but you should really plan for expansion. So, your scopes should be:

192.168.100.65 - 95
192.168.100.97 - 127
192.168.100.129 - 159

with a 255.255.255.224 subnet mask. I kept the first range:

192.168.100.33 - 63

For use with servers and other devices that might require static IP addresses.
Time to implement rule 2. You're gonna run into problems if you just throw these pc's onto a single network and expect the DHCP server to hand out addresses to the correct PC's. What's gonna happen is that when these clients startup, they're gonna send out a DHCPdiscover message. The DHCP server will recieve this message on its own NIC. Now, depending on which subnet your DHCP servers NIC is on, that will be the scope that which it hands out addresses. So, if your DHCP servers IP addressand subnet mask are:

192.168.100.33

It'll look for a scope that matches the subnet it's on and hand out addresses from only that scope. Of course, we don't have any setup for that subnet so it won't hand out an address. If the DHCP servers IP address was:

192.168.100.65

Then it would start handing out addresses from only that scope and not the others.

To solve this problem, we divide the subnets using routers. We can use:

1) Routers
2) DHCP Relay Agents

by shortbus

We'll use the routers to break up and divide your computers into their proper subnets. The problem we'll run into is that some routers do not forward DHCP messages. In which case, all of our clients not on the same subnet with the DHCP server willnot recieve addresses and will use 169.254.x.x addresses (APIPA).

What you'll have to implement are called DHCP relay agents. Now, if you're using Win2K Server boxes as your routers, you can setup a DHCP Relay Agent through RRAS. A relay agent will forward the DHCP messages through the router and to the DHCP server.

When the DHCP Relay Agent recieves the DHCP messages, it will alter them and set a value on the message indicating the source subnet of the message. Based on subnet that the DHCP relay agents NIC is on, is how it will determine the subnet.

So when the DHCP Relay Agent forwards the messages to the DHCP Server, the DHCP server will see what subnet it came from, pull the address from the proper scope and offer it to the client. It'll send this message back to the DHCP Relay Agent who will then send it to the client.

Cool, huh?

Bus

This discussion is closed to new replies.