Saturday, April 27, 2019

Install PowerShell and VMware PowerCLI on macOS



Install PowerShell and VMware PowerCLI on macOS

Install Powershell on Mac
brew cask install powershell

Now, to launch a PowerShell session in macOS, enter the following in terminal.
pwsh

Set Repository for Find Vmware module
Set-PSRepository -Name "PSGallery" -InstallationPolicy "Trusted"

Find Vmware module
Find-Module "VMware.PowerCLI" | Install-Module -Scope "CurrentUser" -AllowClobber

Install Vmware PowerCLI
Get-Module "VMware.PowerCLI" -ListAvailable | FT -Autosize

And if you’d like to see all of the VMware installed modules, run the following.
Get-Module "VMware.*" -ListAvailable | FT -Autosize

As new versions of VMware.PowerCLI is released, you can run the following command to update it.
Update-Module "VMware.PowerCLI"

Let’s test connecting to vCenter server…
Connect-VIServer -Server "<Server_Name>"

To bypass this, enter the following command and then enter “Y” when prompted.  This will set the parameter for the current user.

Set-PowerCLIConfiguration -InvalidCertificateAction "Ignore"

No comments:

Post a Comment

Ethical Hacking Techniques: Cracking WPA/WPA2 Wi-Fi Using WPS and Capturing Handshakes

In the realm of cyber security, ethical hacking plays a crucial role in identifying and addressing vulnerabilities. One of the areas where e...