14.4. Enabling Address Conflict Detection


You want to enable address conflict detection on a DHCP Server. With conflict detection enabled, the DHCP Server will ping the IP address it wants to grant a lease for to make sure no other computers are using that IP address. If the ping request receives a reply, the server will mark the IP as BAD_ADDRESS.


Using a graphical user interface

  1. Open the DHCP snap-in.

  2. In the left pane, right-click on DHCP and select Add Server.

  3. Type in the name of the DHCP Server you want to target and click OK.

  4. Right-click the server in the left pane and select Properties.

  5. Click the Advanced tab.

  6. Enter the number of ping attempts beside Conflict detection attempts. I highly recommend you use either 1 or 2.

  7. Click OK.

Using a command-line interface

The following command configures conflict detection:

> netsh dhcp server \\<ServerName> set detectconflictretry <PingAttempts>

This command displays the current conflict detection setting:

> netsh dhcp server \\<ServerName> show detectconflictretry

Using VBScript

See Recipe 14.0 for more information on how to run the netsh command from within a script.


Enabling address conflict detection is generally a good idea so clients don't obtain an IP address in use by another computer. The DHCP Server will ping the IP address it is about to grant to ensure nothing responds. You can configure the number of ping attempts, but one or two should be sufficient in most cases.

You might wonder why conflict detection is even ...

Get Windows Server Cookbook now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.