VMware PowerCLi Repo
SCRIPTS
No | Script | Description |
---|---|---|
1 | Copy-VMNotes2ComputerDescription.ps1 | Copy VMware VM Notes to Computer/AD Computer Account Description |
2 | Kickstart-VMHostIMM.ps1 | Kickstart ESXi hosts on IBM/LENOVO servers without PXE using PowerShell |
3 | Find-VC.ps1 | Search VCenter VM throw direct connection to group of ESXi hosts |
MODULES
Vi-Module VMware VI Automation Module
Requirements: PowerShell 5 or above. To check, type the following command: $PSVersionTable.PSVersion.Major
.
To install this module, drop the entire 'Vi-Module' folder into one of your module directories.
The default PowerShell module paths are listed in the $env:PSModulePath
environment variable.
To make it look better, split the paths in this manner: $env:PSModulePath -split ';'
The default per-user module path is: "$env:HOMEDRIVE$env:HOMEPATH\Documents\WindowsPowerShell\Modules"
.
The default computer-level module path is: "$env:windir\System32\WindowsPowerShell\v1.0\Modules"
.
To use the module, type following command: Import-Module Vi-Module -Force -Verbose
.
To see the commands imported, type Get-Command -Module Vi-Module
.
For help on each individual cmdlet or function, run Get-Help CmdletName -Full [-Online][-Examples]
.
No | Function | Description |
---|---|---|
1 | Get-RDM | Get all VM with their RDM (Raw Device Mappings) disks |
2 | Convert-VmdkThin2EZThick | Inflate thin virtual disks |
3 | Find-VcVm | Search VCenter VM throw direct connection to group of ESXi hosts. Thanks to VMGU.ru for the article |
4 | Set-PowerCLiTitle | Write connected VI servers info to PowerCLi window title bar |
5 | Get-VMHostFirmwareVersion | Get a Firmware version and release date of your ESXi hosts |
6 | Compare-VMHostSoftwareVib | Deprecated. Use Compare-VMHost -Compare VIB instead |
7 | Get-VMHostBirthday | Get ESXi hosts' installation date. Thanks to Magnus Andersson for his idea |
8 | Enable-VMHostSSH/Disable-VMHostSSH | Enable/Disable SSH on all ESXi hosts in a cluster |
9 | Set-VMHostNtpServer | Set NTP Servers setting on ESXi hosts |
10 | Get-Version | Get VMware Virtual Infrastructure objects' version info: VM , ESXi Hosts , VDSwitches , Datastores , VCenters , PowerCLi , License Keys |
11 | Compare-VMHost | Compare two or more ESXi hosts with PowerCLi |
12 | Move-Template2Datastore | Invoke Storage VMotion task for VM Template(s) |
13 | Connect-VMHostPutty | Connect to ESXi host(s) by putty SSH client with no password! |
14 | Set-MaxSnapshotNumber | Set maximum allowed VM snapshot number |
15 | Get-VMHostGPU | Get ESXi host(s) GPU info |
16 | Test-VMHotfix | Test VM for installed Hotfix(es) |
17 | Test-VMPing | Test VM accessibility |
18 | Search-Datastore | Browse/Search VMware Datastores |
19 | Get-VMHostPnic/Get-VMHostHba | Get ESXi hosts Peripheral devices |
20 | Set-SdrsCluster/Get-SdrsCluster | Configure Storage DRS clusters |
21 | Add-SdrsAntiAffinityRule/Get-SdrsAntiAffinityRule/Remove-SdrsAntiAffinityRule | Create and delete SDRS Anti-Affinity Rules |
22 | Invoke-SdrsRecommendation | Run Storage DRS recommendations |
23 | Set-SdrsAntiAffinityRule | Configure SDRS Anti-Affinity Rules |
24 | Convert-VI2PSCredential | Securely save and retrieve credentials |
25 | Get-VMGuestPartition/Expand-VMGuestPartition | Extend VM Guest Partition |
VSAN
No | Function | Description |
---|---|---|
1 | Get-VSANHealthCheckSupported | Get all available VSAN Health Checks. Idea by William Lam |
2 | Get-VSANHealthCheckSkipped | Get skipped VSAN Health Checks. Idea by William Lam |
3 | Get-VSANHealthCheckGroup | Get all VSAN Health Check groups. Idea by William Lam |
4 | Enable-VSANHealthCheckSkipped | Enable skipped VSAN Health Check(s). Idea by William Lam |
5 | Disable-VSANHealthCheck | Disable VSAN Health Check(s). Idea by William Lam |
6 | Get-VSANSmartData | Get SMART drive data. Idea by William Lam |
7 | Get-VSANVersion | Get VSAN health service version. Idea by William Lam |
8 | Get-VSANHealthSummary | Fetch VSAN Cluster Health status |
9 | Invoke-VSANHealthCheck | Run VSAN Cluster Health Test |
10 | Get-VSANCapability | Get VSAN capabilities |
VAMI Virtual Appliance Management Interface
No | Function | Description |
---|---|---|
1 | Get-VAMIHealth | Get Appliance health summary |
2 | Get-VAMISummary | Get basic Appliance info |
3 | Get-VAMIAccess | Get access interfaces |
4 | Get-VAMIBackupSize | Get estimated backup size |
5 | Get-VAMIDisks | Get VMDK disk number to OS partition mapping |
6 | Get-VAMIStorageUsed/Start-VAMIDiskResize | Get OS partition usage & Resize partition |
7 | Get-VAMINetwork | Get networking info |
8 | Get-VAMIPerformance | Get CPU% & Memory% usage |
9 | Get-VAMIService/Restart-VAMIService/Start-VAMIService/Stop-VAMIService | Get & control services' state |
10 | Get-VAMIStatsList | Get available monitoring metrics |
11 | Get-VAMITime | Get current Time and NTP info |
12 | Get-VAMIUser/New-VAMIUser/Remove-VAMIUser | Manipulate local users |