Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 395
  • Last Modified:

Finding Physcial Machine Mac on Virtual Client

Does  anybody know a way to get the physical mac/IP off a virtual machine without physically going to each location?
0
bgbies
Asked:
bgbies
  • 4
  • 4
  • 2
  • +1
1 Solution
 
coolsport00Commented:
Log into vCenter or the ESX/i host the VM resides on with vSphere Client. Rt-click on the VM ->> Edit Settings. Select the Ethernet Adapter in the list of hardware. Then on the right side you should see the MAC address of the VM.

~coolsport00
0
 
coolsport00Commented:
If you want a list of MAC addy's of all VMs in your infrastructure, there is probably a scripted way to get it, though I don't have a script for that.

~coolsport00
0
 
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
ping the Ip Address and look in your arp cache

arp -a

RV Tools
http://www.robware.net/

CC-Get Mac Address
http://www.youngzsoft.net/cc-get-mac-address/

it will get Mac from IP, and vice versa, nice little program to have in your toolkit for little money.


VMware Community Pack
http://www.virtu-al.net/featured-scripts/vmware-powerpack/

Scripts in above have MAC Address

or here, been using this for years...

## get VirtualMachine .NET views where the items is not marked as a Template
$colDevMacAddrInfo = `
Get-View -ViewType VirtualMachine -Property Name,Config.Hardware.Device -Filter @{"Config.Template" = "False"} | %{
   $strVMName = $_.Name
   $_.Config.Hardware.Device | Where-Object {$_ -is [VMware.Vim.VirtualEthernetCard]} | %{
       New-Object -Type PSObject -Property @{VMName = $strVMName; MacAddr = $_.MacAddress}
   } ## end foreach-object
} ## end foreach-object

## are all of the MAC addresses unique?
($colDevMacAddrInfo | Select-Object -unique MacAddr).Count -eq $colDevMacAddrInfo.Count

## get the non-unique MAC addresses, returning objects with the count of the duplicates, the duplicate MAC, and the VM names that have the duplicate MAC
$colDevMacAddrInfo | Group-Object MacAddr | Where-Object {$_.count -gt 1} | Select-Object Count,@{n="DuplicateMAC"; e={$_.Name}},@{n="VMNames"; e={($_.Group | %{$_.VMName}) -join ","}}

Open in new window

0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
bgbiesAuthor Commented:
This was my fault for not phrasing the question correctly, I am looking to get the IP (preferably) off from the physical machine, not the virtual.
0
 
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
You want to find the IP Address of the physical host from the VM?
0
 
coolsport00Commented:
ping the hostname of the host via cmd line.
0
 
achaldaveCommented:
you can user powercli

get-vmhost | get-vmhostnetworkadapter | ft -property name,mac,ip,vmhost

or

http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1001167
0
 
bgbiesAuthor Commented:
"You want to find the IP Address of the physical host from the VM? "
Yes, we were able to find it in the registry key.  Thaks everybody!
0
 
bgbiesAuthor Commented:
0
 
coolsport00Commented:
Ok, so even more specifically, you're talking about VMware View and when logged onto a VM desktop, you want to get the IP of the Client that is connected to that VM?
0
 
bgbiesAuthor Commented:
The physical client's IP is in virtual machines registry.
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

  • 4
  • 4
  • 2
  • +1
Tackle projects and never again get stuck behind a technical roadblock.
Join Now