Another week. Another park. This one a little to busy to stick around at for too long in this day and age but I still got a few nice pictures before high tailing it out of there.
Monthly Archives: July 2020
I am very lucky to live in the Province that I do in Canada. We have some of the most amazing places that you can visit in nature. A few days ago my Mother and I visited Lightouse Park again and these are some of the photos of that trip.
Part of my job responsibilities are managing a large VMware installation and a tool which I use frequently, is PowerShell with the VMware modules. The following is only how I installed it on macOS and is by far not the only way.
First, I use Brew, it just makes things easier for me to get all the tools that I require and keep them up to date easily. Click here if you could like to know how to install Brew.
Installing PowerShell via Brew
Installing PowerShell via Brew is very easy and can be done via a simple command:
brew cask install powershell
Once this is complete you can access PowerShell in one of two different ways. The first is once the installation is complete you’ll have a PowerShell icon in your applications folder. However, the easier way to access PowerShell will be via Terminal and typing:
Installing VMware modules into PowerShell
Next we will install the VMware modules, which is why we’re putting sudo in front so that we’re working as an Administrator.
sudo pwsh Find-Module -Name VMware.PowerCLI Install-Module -Name VMware.PowerCLI -Scope CurrentUser
Now let’s verify that everything got installed
Get-Command -Module *VMWare*
If everything went as expected you’ll see a long list of VMware modules.
Connecting to your vCenter
Connect-VIServer -Server vcenter.host.local -User firstname.lastname@example.org -Password
So, now what?
For more detailed documentation that what’s found here, click this link.
To get a list of all your virtual machines:
If you want to see a lot more information about each machine you can have that information spit out in a nice format list, like this:
get-vm | fl
A common task is moving virtual machines from here to there as users believe that memory and CPU are infinite. The following command would move the VM to the new ESXi host, via vMotion:
Move-VM -VM 'vmname' -Destination 'newesxi host'
The point of this post was to get everyone up and running on macOS with PowerShell and VMware. There are many resources on-line that will help you continue your journey.