Configuring the network of virtual machines

To configure the network of a virtual machine guest operating system, you can use the Invoke-VMScript cmdlet, to run scripts in the guest operating system of a virtual machine. You have already seen the Invoke-VMScript cmdlet in Chapter 5, Managing Virtual Machines with PowerCLI .

To configure the network of Microsoft Windows virtual machines with PowerShell V3 or later versions installed, you can use the cmdlets in the netadapter and NetTCPIP modules to modify network adapters and TCP/IP settings. For Microsoft Windows virtual machines with PowerShell V1 or V2 installed, you can use the Windows Management Instrumentation (WMIGet-WMIObject cmdlet with the Win32_NetworkAdapterConfiguration class. In ...

Get Learning PowerCLI - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.