Some important configurations and procedures, when using VMware solutions, you will need to know and how to operate using PowerCLI. If you don’t know what PowerCLI is or have questions about this, you can check this link .
VMware PowerCLI is a command-line and scripting tool built on Windows PowerShell which you can use during management and automation script using vSphere, vRealize Operations Manager, vSAN, NSX-T, VMware Cloud on AWS, VMware HCX, VMware Site Recovery Manager and of course, VMware Horizon.
This post will cover how to install PowerCLI in order to use for future configurations an scripts using VMware Horizon.
Offline Mode – Download and Install PowerCLI
In case you don’t have internet access from the server you’re working ont, first of all, you need to download VMware PowerCLI from this link an copy it into a USB thumb drive. You can see some good information at the same site like compatibility matrix, PowerCLI User Guide, Cmdlet reference etc.
As soon you download the ZIP file, copy it into the server you’re about to install PowerCLI, you need to put all files into System-wyde module folder, which is the following path into your Windows Server:
When you extract its content, you can see the following files on the path:
Online Mode – Easy One
Just follow the steps below to install PowerCLI:
- Find-Module -Name VMware.PowerCLI
- Install-Module -Name VMware.PowerCLI -Scope CurrentUser
- Get-Command -Module *VMWare*
PowerCLI Configurations Prior Start Using it
Open a Windows PowerShell to perform the configuration:
Type the following command line to configure PowerCLI:
If the command issued problems for you, try to use the following added information to your command line:
Set-ExecutionPolicy RemoteSigned – Scope CurrentUser
Now it’s time execute PowerCLI configuration steps. I usually use this command line to configure PowerCLI:
Set-PowerCLIConfiguration -Scope AllUsers -ParticipateInCEIP $false -InvalidCertificateAction Ignore
As you can see, I typed in the sequence an Import-Module command asking for VMware Automation from Horizon and I got no errors coming from PowerShell.
Welcome to the world of PowerCLI! You can see a lot of good stuff from the following website also:
Enjoy the ride!