Hp Nic Teamed Servers - script to return all mac addresses

A portion of the script:
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")

Set colItems = objWMIService.ExecQuery _
    ("Select * from Win32_NetworkAdapter")

Script works fine and returns mac address.  But it only returns the mac address of the virtual NIC.  It does not show the nic of the physical adapters.

Any ideas?
tom_sc1Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Joseph DalyCommented:
Have you tried the following using network adapter configuration?
strComputer = "." 
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\CIMV2") 
Set colItems = objWMIService.ExecQuery( _
    "SELECT * FROM Win32_NetworkAdapterConfiguration",,48) 
For Each objItem in colItems 
    Wscript.Echo "-----------------------------------"
    Wscript.Echo "Win32_NetworkAdapterConfiguration instance"
    Wscript.Echo "-----------------------------------"
    Wscript.Echo "MACAddress: " & objItem.MACAddress
Next

Open in new window

0
tom_sc1Author Commented:
no this still returns only the virtual nic's mac.  It does list out the individual adapters but only lists the virtual mac and not each bia.

Not sure this is possible using vbs

Thanks
0
Joseph DalyCommented:
I think you may be right. But you may be able to get this info via SNMP. Take a look at the following link.
http://www.brianmadden.com/blogs/guestbloggers/archive/2006/04/19/hp-proliant-network-adapter-teaming-explained.aspx

Search for WMI about 3/4 down the page and you can see there is a MIB file on the smartstart cd you can use to get the MAC addresses of the physical
0
tom_sc1Author Commented:
I ended up logging into each machine and opening the net config utility and copying each bia.  I think HP has a scripting engine that I could have used but sometimes the manual way is easier.  Even if it was 50 servers!

Thanks for all your replys.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Windows Server 2003

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.