your home for end-user virtualization!

Powershell

Reset the vSphere Memory Limit using PowerCLI

If you’ve ever migrated clusters or joined VM’s from a different cluster, I’m sure you’ve run into the bug where memory limits are set on the VM’s automatically. To remove this, simply use the powerful oneliner below! Get-VM | Get-VMResourceConfiguration | where {$_.MemLimitMB -ne ‘-1’} | Set-VMResourceConfiguration -MemLimitMB $null

Tags: , ,

Posted in Cloud, PowerCLI, Powershell, vmware | No Comments »

List the Hostname, Cluster Name, Memory Size, CPU Sckets and CPU Cores of each ESX host using PowerCLI

List the Hostname, Cluster Name, Memory Size, CPU Sckets and CPU Cores of each ESX host using PowerCLI $myCol = @() ForEach ($Cluster in Get-Cluster) { ForEach ($vmhost in ($cluster | Get-VMHost)) { $VMView = $VMhost | Get-View $VMSummary = “” | Select HostName, ClusterName, MemorySizeGB, CPUSockets, CPUCores $VMSummary.HostName = $VMhost.Name $VMSummary.ClusterName = $Cluster.Name $VMSummary.MemorySizeGB […]

Tags: , ,

Posted in Cloud, PowerCLI, Powershell, vmware | 1 Comment »

Find all snapshots within your vCenter environment using PowerCLI

Find all snapshots within your vCenter environment using PowerCLI $snaplist = Get-View -ViewType VirtualMachine -Filter @{“snapshot”=”$snaplist”} $snaplist | select name

Tags: ,

Posted in Powershell, vmware | No Comments »

Add a new NFS datastore to all of the hosts in a cluster using PowerCLI

Needing a way to add a NFS to multiple hosts, I resorted to using VMware’s API PowerCLI! get-vmhost | New-Datastore -Nfs -Name DataStoreName -Path /data1/export -NfsHost nfshost.domain.local

Tags: ,

Posted in Powershell, vmware | 2 Comments »

Search

Categories