Windows Vista Tips

Windows Vista Tips > Newsgroups > Windows Server > Scripting > script to get MAC address info. from DHCP

Reply
Thread Tools Display Modes

script to get MAC address info. from DHCP

 
 
SalemOR97301
Guest
Posts: n/a

 
      09-12-2008
I have an application that I need to import all the MAC addresses for all
hostnames into. I haven't found a way other than to an nbtstat -a
COMPUTERNAME. Of course the only issue with that one is the machines have to
be powered on to get a result. Is there any way to extract the MAC address
from DHCP?

Thank You,

--GT--


 
Reply With Quote
 
 
 
 
Shay Levy [MVP]
Guest
Posts: n/a

 
      09-16-2008

Try with netsh:

C:\> netsh -c dhcp server scope 192.168.1.0 show clients



---
Shay Levy
Windows PowerShell MVP
http://blogs.microsoft.co.il/blogs/ScriptFanatic
PowerShell Toolbar: http://tinyurl.com/PSToolbar


S> I have an application that I need to import all the MAC addresses for
S> all hostnames into. I haven't found a way other than to an nbtstat -a
S> COMPUTERNAME. Of course the only issue with that one is the machines
S> have to be powered on to get a result. Is there any way to extract
S> the MAC address from DHCP?
S>
S> Thank You,
S>
S> --GT--
S>


 
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
RE: All DHCP Servers Info HELP! Adam Wylie Active Directory 4 11-21-2006 01:42 PM
DHCP gives client address but no gateway address mheymann Server Networking 4 06-09-2006 12:29 PM
DHCP gives client address but no gateway address mheymann Windows Small Business Server 0 06-08-2006 07:11 PM
DHCP: how can a reserved IP address get assigned to another DHCP c Terry Windows Server 2 05-31-2005 11:18 PM
DHCP info to XP Clients R Harrigill Server Networking 1 12-10-2004 10:53 PM



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59