Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Static IP on the DHCP Server 1

Status
Not open for further replies.

jrlh

Technical User
Apr 19, 2002
18
0
0
GB
Is it posible to create a static IP on the DHCP Server for a workstation without creating a static IP address on the the workstation?
 
Yes actually you can. You can reserve an IP address for a specific computer on the DHCP. Are you using Win2k server or NT server?
 
A DHCP server can use a custom DHCP client identifier to reserve an IP address for a specific network interface card. If the NIC is replaced, the new NIC will receive the same IP address from the DHCP server. When a Windows NT DHCP client sends a client identifier to a DHCP server, it sends the identifier as 4 bytes, or 8 hexadecimal characters. The identifier is sent in groups of two hexadecimal characters, with these groups of two sent in reverse order. If the identifier is less than 8 hexadecimal characters, then zeros are padded at the end of the identifier. For example:

Custom Client Identifier Client Reservation on DHCP Server

12345678 78563412
123456 56341200
1234 34120000
1234567 67452301
12345 45230100
123 23010000
A18F42 428FA100
CF432 32F40C00
C32D1BE BED1320C
When you create a scope, you specify that client leases should be assigned either with a fixed expiration date or with an unlimited expiration date. A fixed expiration date is usually the best option. You can then supplement this with address reservations for clients that need semipermanent IP addresses.

Managing Client Leases
To open this dialog box, select the scope in the DHCP Manager and then choose Active Leases from the Scope menu. The primary fields of this dialog box are used as follows:
Total Addresses in Scope Shows the total number of IP addresses assigned to the scope. Active/Excluded Shows the total number of active or excluded addresses as a numerical value and a percentage of the total available addresses.
Tip Think of the Active/Excluded field as the number of addresses used up. If the percentage total reaches 85 percent or more, you may want to consider assigning additional addresses or freeing up addresses for use.
Available Shows the total number of addresses available for use as a numerical value and a percentage of the total available addresses. Client Shows the active leases or reservations for the currently selected scope. Clients are listed by IP address and by client name. If the IP address is reserved, the listing is followed by the keyword Reservation. Select the Show Reservations Only check box to only display reservations in the Client list box.
Properties Displays the properties of the lease or reservation selected in the Client list box. Delete Deletes the currently selected lease or reservation. Reconcile Reconciles the client leases and reservations against the DHCP database on the server. This is useful if you want to ensure that the list of leases shown is actually in use.
Refresh Refreshes the listings in the Client list box.
Reserving DHCP Addresses DHCP provides several ways to provide permanent addresses to clients. One way is to use the Unlimited setting in the Scope dialog box to assign permanent addresses to all clients that use the scope. Another way is to reserve DHCP addresses on a per-client basis. When you reserve a DHCP address, the client is always assigned the same IP address by the DHCP server, and you can do so without sacrificing the centralized management features that make DHCP so attractive. To reserve a DHCP address for a client, follow these steps:
In the DHCP Manager, select the scope you want to work with and then choose Add Reservation from the Scope menu. In the IP Address field, enter the IP address you want to reserve for the client. Note that this IP address must be within the valid range of addresses for the currently selected scope. The Unique Identifier field specifies the MAC (media access control) address for the client computer's network adapter card. You can obtain the MAC address by typing the command net config wksta at the Command prompt on the client computer. This value must be typed exactly for the address reservation to work. In the Client Name field, enter the computer name for the client. This field is used for identification purposes only and doesn't affect the client's actual computer name. Enter an optional comment in the Client Comment field if you like. Select Add to create the address reservation. Releasing Addresses and Leases
When you work with reserved addresses, there are a couple of caveats you should know about: Reserved addresses aren't automatically reassigned. So if the address is already in use, you'll need to release the address to ensure that the appropriate client can obtain it. You can force a client to release an address by terminating the client's lease or by logging on to the client and typing the command ipconfig/release at the Command prompt. Clients don't automatically switch to the reserved address. So if the client is already using a different IP address, you'll need to force the client to release the current lease and request a new one. You can do this by terminating the client's lease or by logging on to the client and typing the command ipconfig/renew at the Command prompt. The Client Properties dialog box allows you to modify lease and reservation properties.
 
Thanks for clearing that up. I had only known one way and that was to assign it locally.

Thanks once again.

[2thumbsup]
 
I have a question regarding DHCP reservations, what if you have two servers each running dhcp, server 'A' services one subnet and server 'B' services another subnet. but to create redundancy i want to split the scopes between the two servers so one server handles half of both subnets ie: server 'A' has a subnet 1 range of 192.168.103.1 to 192.168.103.100 and also has a subnet 2 range of 192.168.104.101 to 192.168.104.254 incase server 'B' dies. Now if i have a reservation on server 'B' for a client that must have this ip of say 192.168.104.1 and then server 'B' dies so the client looks at server 'A' for an address but server 'A'only has a scope of 192.168.104.101 to 192.168.104.254 so how do i set a reservation or can i do it on both dhcp servers?
 
Unfortunately you won't be able to add the reservation to each server unless it is in the scope. DHCP will not allow it. In a situation like that here are a few suggestions you can use.


1- You can leave the reservation on 1 Server and if that server happens to go down the computer will receive an IP regardless. The downside is it defeats the purpose of having a reservation depending on why you need a reservation.


2- You can create reservations on Each DHCP server that are within each scope. The downside to this is that it's impossible to tell which IP the client is going to receive since both servers are running at the sametime. (back to the first problem)


3- If running Win2k Server SP1 you can use DHCPEXIM to import/export DHCP server information to another 'standby' server (of course one that you would not be able to use unless the server went down). The server is going to have to be fairly powerful so keep in mind DHCP is very resource intensive and this may or may not be the most economical for your situation. Also if you are using Windows NT Server there is some very good software you can purchase to accomplish the samething the DHCPEXIM tool in Win2k Server or you can check this article which the risks are in my opinion not worth the effort. .

I haven't heard of an easy solution in a situation such as this so I don't know what else to suggest (besides just leaving it alone j/k).

Sorry if that wasn't very helpful. -Brad
A+, MCSE NT4, MCDBA SQL7

-Best cartoon of all time :-D 'Spongebob Squarepants' [cook]
 
Thanks Brad, your information was helpful think we may head toward your option number three. if i can export the scope and put it on another server and just not 'activate' the scope until i need it would be the simplest way although if something did happen i would need to log on and activate it rather than having a seemless transition. but thanks again for clarifying that up for me. :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top