Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Question
Tuesday, January 25, 2011 1:22 PM
How do I know which DHCP leases are leased by DHCP server in cmd.exe ? Or.. whiat IP addressed from scope are in use at the moment ?
All replies (10)
Wednesday, January 26, 2011 7:24 AM ✅Answered | 1 vote
Hi,
Thanks for posting here.
Prachand is right that using Netsh utility is the way to achieve your goal. Here is the example for you refer:
I have a scope for subnet 192.168.1.0/24, so i performed “Netsh dhcp server scope 192.168.1.0 show clients” and all lease information should be returned .
How to find out all the active clients serviced by your DHCP server
Thanks.
Tiger Li
Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.
Tuesday, January 25, 2011 1:40 PM
Open the DHCP MMC
Click on the Server name
Click on Scope
Click on the Address Leases
You will get the list of ip leased by the DHCP from the scope
You can also use the kb http://support.microsoft.com/kb/281626 to to export and import DHCP scopes from the cmd
The technet has all the Netsh commands for DHCP
http://technet.microsoft.com/en-us/library/bb490941.aspx
Tuesday, January 25, 2011 1:54 PM
I need to do it in cmd, not in windows forms. Also how can i export leases, using cmd.
Tuesday, January 25, 2011 2:01 PM
Have a look at this
Netsh commands for DHCP http://technet.microsoft.com/en-us/library/bb490941.aspx
Tuesday, January 25, 2011 2:14 PM
On the cmd type netsh dhcp server show all
This command lists all current server status and configuration details, including the stored management information base (MIB) information, for the currently specified DHCP server
netsh dhcp server show scope Showes the scope
Tuesday, January 25, 2011 2:16 PM
I've seen this, but haven't found anything useful. It can be export ti file, but i don't know how to do it, using cmd.
Tuesday, January 25, 2011 2:18 PM
but without information about leases.
Tuesday, January 25, 2011 2:19 PM
Or you can tell me, how to open mdb file, and found information there.
Tuesday, January 25, 2011 2:28 PM
I am not able to find any information about that, will try to get that and keep you posted.
Wednesday, January 26, 2011 8:11 AM
Thanks Tiger, you are great help as always.