Quantcast
Channel: VMware Communities : All Content - VMware PowerCLI
Browsing all 16717 articles
Browse latest View live

Export DRS rules including DRS groups

I'm looking for a way to export a listing of DRS groups. I found some scripts that will export/import DRS rules, but they ony apply to affinity/anti-affinity for VMs - like these:...

View Article


PowerCLI & Workflow

Hi, I'm trying to convert a powercli script to use workflow (mostly so I can run cloning in parallel).  Will I have to wrap every "get-vm" etc in an "inlinescript {}" definition? -T

View Article


wait for completion of CloneVM_Task

Hi, i am new to Powershell and PowerCLI and already searched the net and this forum for the answer of my question but had no success so far. I want to write a script that Clones a VM and informs about...

View Article

Total of vm.provisionedSpaceGB and Datastore.provisionedGB not equal

I was looking to find the storage growth rate in my environment when I noticed something interesting.  When I query the VMs and the Datastores on provisioned space I get different numbers where I would...

View Article

Image may be NSFW.
Clik here to view.

List VM name and sum of (provisioned) VM disk size and export it

Hello, I need to list all VM:s and their provisioned disk space. I can do it with this command:get-vm * | foreach-object {write-host "$_`t" (Get-HardDisk -vm $_ | Measure-Object -Property CapacityGB...

View Article


Triggered Alarm Object

Hi, I'm trying to create a script that sends an email with all of the daily alarms from VMware.  I have it all done but the part that finds the object that is actually in alarm.  I'm using the code...

View Article

Controlling multiple VM's across multiple hosts?

Hi, Apologies for what is clearly going to be a newbish question as I've just started using PowerCLI yesterday. I have 6 Host servers with 10 VMs on each and each VM with a snapshot. I've created a...

View Article

Copy-DatastoreItem with / in the Datacentre Name

Hi All, I am trying to copy VM's VMDK files from VMware stores to my local C:\ computer and coming across a problem using the PowerCLI 5.1 cmdlet Copy-DatastoreItem when Data center has forward slash /...

View Article


Performance Metrics

Hello, would have a question - because it's confusing me in the Moment. i'am trying to calc "CPU Ready"  the summation Value to an more reliable Value once analyzing  dayli,weekly,monthly. Based on...

View Article


list disks rdm with powershell

 Hello ,   i like how lists disk rdm of a vm .Command get-hardisk give me location vmdk , capacity , but i want more informatation disks RDMs   Por example , i want to list imformation like vmhba...

View Article

Having trouble populating Owner CustomAttribute

Get-VM | Select @{N="VM";E={$_.name}},@{N="Tools Version";E={$_.version}},@{N="Owner";E={(Get-VM $_.name | Get-Annotation -CustomAttribute "Owner")}} |Export-Csv tools.csv  -NoTypeInformation

View Article

Booting A Windows Guest?

Hi, Anyone know how I can tell when a windows guest has completed booting and the "Press CTRL +  ALT + DELETE to log on" console splash screen is showing ?  I want to run a script on the guest just...

View Article

Script need for network adapter and Vswitch info

HiCan anyone having script to list out the outlput of network/vsiwtch info like below for all cluster in VC in csv format. Hostname           mcadress Physical adapter name     Vswitch name   Vswitch...

View Article


Set SCSI Preferred on "Runtime Name"

Hi, I need to set SCSI preferred Pathes with Path selection policy "Fixed". In my enviroment I can only identify the Path, which is the preferred on on the "runtime Name" of the Path. Is there an way...

View Article

How to delete snapshot parallel on multiple VM by PowerCLI?

Greeting, I'm looking for a way to delete snapshots on multiple VM parallelly.I know delete snapshot by following script:get-vm -location xxx | remove-snapshot     The script above delete snapshots one...

View Article


PowerCLI sort by folder in vCenter

I am using powercli and get-vm to generate a list of VMs and configuration items. I  would like to somehow list what folder in vCenter a VM is in, and then sort the VMs by folder, and then by name in...

View Article

Verify vshield endpoint via PowerCLI?

     As we roll out Trend Deep Security, I need to be able to verify whether the vshield endpoint driver is installed on all machines in my environment, and provide a report with the status of each...

View Article


List VM HA restart priority

Hi all Is there a way to list the HA restart priority for all the VMs in a cluster? Maybe with PowerCLI?I found some information about a powershell possibility for ESXi 5.1/vSphere 5.1 but I'm still...

View Article

Script to check for Orphaned Files and Invalid Snapshots

Hi All I have created a Powershell script that checks for Orphaned Files and Invalid Snapshot images.The Orphaned Files part of the check is using Luk Dekens function for finding and removing phantom...

View Article

Image may be NSFW.
Clik here to view.

Creating Folder Structure

Trying to find a quick way to import all the VM & Templates (aka BLUE Folders) from Site A to Site B.  Each Site has its own vCenter with multiple "Datacenters" located inside.  I just want all the...

View Article
Browsing all 16717 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>