Differences between revisions 2 and 3
Revision 2 as of 2019-03-29 07:06:09
Size: 750
Editor: localhost
Comment:
Revision 3 as of 2019-05-29 01:32:32
Size: 749
Editor: merlyn
Comment:
Deletions are marked like this. Additions are marked like this.
Line 23: Line 23:
=== Script to list VM Network Adapter Type, exporting issue ===  === Script to list VM Network Adapter Type, exporting issue ===

Install

Windows 2008R2

Install-Module VMware.PowerCLI -Scope CurrentUser

Configration

Set-ExecutionPolicy RemoteSigned
Set-PowerCLIConfiguration -ProxyPolicy NoProxy
Set-PowerCLIConfiguration -InvalidCertificateAction Ignore

Use

Connect-VIServer -server 192.168.25.60 -Protocol https -Username 'administrator@vsphere.local'

Script to list VM Network Adapter Type, exporting issue

Get-VM | Get-NetworkAdapter | 
Where-object {$_.Type -ne "Vmxnet3"} | 
Select @{N="VM";E={$_.Parent.Name}},Name,Type |
export-Csv  c:\Network_Interface.csv -NoTypeInformation

désert/VMware/PowerCLI (last edited 2020-07-24 15:03:34 by localhost)