PowerCLI 4.0 U1 makes it easy to connect to multiple vCenters or ESX hosts at the same time and automate across all of them using PowerCLI's more than 200 cmdlets. This video shows how it works.
Check out http://blogs.vmware.com/vipowershell for more information.
The default (at least for PowerCLI 4.1) is to allow only a single session at a time. You can change that with -
set-powercliconfiguration -defaultviservermode Multiple
To query the current setting use -
get-powercliconfiguration
DaveMishchenko 1 year ago
This doesn't work for me. I connect to one, get-vmhost/$global:defaultVIservers shows me 1 host. I connect-viserver vc#2, get-vmhost/$global:defaultVIservers shows the last connected VC (or ESX Host)
arsenx 2 years ago