How to assign IP address to computer on XP Pro network

1

If I go into TCP/IP settings to manually set an IP address for an XP machine, what should be set for:

  • Subnet mask
  • Default gateway

What would happen if I set an IP address that is already assigned to another machine?

If I set a machine to be a certain IP number, will the DHCP server know not to try to give that IP address to another machine that joins the network?

CJ7

Posted 2010-06-24T12:42:51.950

Reputation: 1 060

Answers

1

To answer your question, you first have to understand how IP addresses are allocated. (Note that this is a overly simplified version intended to be understandable with little background knowledge, and is not very technically accurate)

For example, if you are using private address space: 192.168.1.0 to 192.168.1.255:

192.168.1.0 represents the network
192.168.1.255 represents the broadcast address

192.168.1.1 to 192.168.1.254 are usable addresses for computers

Quite often, 192.168.1.1 represents the router, and thus, you have 192.168.1.2 to 192.168.1.254 on your disposal.

In this case, you have:

network 192.168.1.0
netmask 255.255.255.0
default gateway 192.168.1.1

the netmask, [11111111].[11111111].[11111111].[00000000] (when expanded in binary), indicates that in an arbitary address, no matter what you put in the '0' part, you are still within your network provided that the '1' part is equal.

Thus, 192.168.1.24 is in the network 192.168.1.0/255.255.255.0 whereas 192.168.2.24 is not.

In a home router network connected to an ADSL modem, the usual default gateway is the router itself, and the network mask is usually 255.255.255.0 (i.e. a class C network). Some routers do use 10.0.0.0/255.255.255.0 though.

In a leased line environment, usually you will be assigned, e.g. 4 address (one router, one broadcast and 2 usable), from, let's say, 123.123.123.4 - 123.123.123.7, then the default gateway is usually 123.123.123.4, and netmask 255.255.255.252 (i.e. 255.255.255.[11111100]) and broadcast 123.123.123.7.

bubu

Posted 2010-06-24T12:42:51.950

Reputation: 9 283

Depending on implementation, most DHCP server I have used do not have that IP-conflict prevention capability. The safe bet is to limit the DHCP server to e.g. x.x.x.100-x.x.x.128, and use x.x.x.1-99 for static IPs. – bubu – 2010-06-24T13:10:52.953

all the DHCP implementations I've used have had the ability to configure particular hosts to have a fixed IP without having to manually allocate, or reserve address range(s) – Rowland Shaw – 2010-06-24T13:54:35.873

@Rowland Shaw I thought the OP asked if the DHCP implementations would allow for detection of current IPs on the network and not allocating these IP out on DHCP request. – bubu – 2010-06-24T15:43:09.690

Seems I missed that edit -- I'll crawl back under my rock :) – Rowland Shaw – 2010-06-24T16:15:37.887

0

Which networks are you going to connect to?

If it is a home router/ADSL device, it usually has DHCP configured but default.
So, you need to do nothing.

Here is a link to some basics on static IP configuration.
You can start from the Home-Network-help homepage if you need to get broader details.

Update on your extra question:
If you choose to use a static IP address, it should be outside the range used by your DHCP server. The server will not know about this allocation because normally, once you setup a static IP on this machine, it will not interact over DHCP with that server.

nik

Posted 2010-06-24T12:42:51.950

Reputation: 50 788

See my extra question. – CJ7 – 2010-06-24T12:59:36.213

0

If you are going to have a mixed DHCP/Static network, you want to make sure that your DHCP server has a limited number of IPs to assign. For example, on my home network, I assign static address to all wired connections, but use DHCP for all wireless connections. I can configure the DHCP server in my gateway router to assign address in the X.X.X.110 to X.X.X.120 range. Since I know what IP range my DHCP server is using, I just assign static IPs from the rest of the pool.

As to assigning an IP already in use to another system, whichever system is first to acquire the network will have use of the IP. Your system configured for DHCP MAY try to request a new IP, but unlikely if it is first onto the network.

As to assigning IPs at random, the only way your DHCP will know not to assign an IP already in use is if the system using that IP is alive on the network. The DHCP will see that and assign another from the avaiable pool.

Sarge

Posted 2010-06-24T12:42:51.950

Reputation: 717