Using netsh command to extract dhcp client list

Applies to Windows Server 2008 and above

Please note that in future versions of Windows, Microsoft might remove the Netsh Functionality for DHCP Server. The recommended usage is with Windows Powershell. We will explore that in a later post.

In this example I have considered DHCP Server as \\mydhcpservername and scope as

Run Command Prompt

netsh dhcp>server
netsh dhcp server>\\mydhcpservername
netsh dhcp server>show scope

Changed the Current Scope Context to Scope

netsh dhcp server scope>show client 1

The above command will list the following in the below order

  • IP Address
  • Subnet Mask
  • MAC Address
  • Lease Expiry
  • Type of Lease
  • Name of Connected Device

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s