Quantcast
Channel: VMware Communities : All Content - All Communities
Viewing all articles
Browse latest Browse all 175326

How to filter similar MAC addresses?

$
0
0

Hi

 

I'm trying to filter out MAC addresses but the MAC column is showing blank.

 

Here's what I have so far:

 

Get-Datacenter $DC | Get-Vm | Get-View |

Select @{N="VM";E={$_.Name}},

    @{N="#NIC";E={($_.Config.Hardware.Device | where {$_.MacAddress} | Measure-Object).Count}},

                @{N="#MAC";E={[string]::Join(',',($_.Guest.Net | %{$_.MacAddress})) | Where-Object {$_.MacAddress -like "00:50:F3*"}}},

@{N="IP addresses";E={[string]::Join('

,',($_.Guest.Net | %{$_.IpAddress}))}}

 

Thanks


Viewing all articles
Browse latest Browse all 175326

Trending Articles