6 thoughts on “Some updates to the PowerCLI Shutdown VMs Script – Now w/ a virtualized vCenter option

  1. Thanks for the updated script. I need to get this updated because I now have an SSO server, Inventory server, and vcenter server. Any ideas the easiest way to exclude all of my vcenter servers from shutting down until the end?

  2. Hi,

    i found your script to be really great, do you mind if i post it on my blog with some changes i made?

    I added the following:

    – support for vApps
    – removed annoying error messages when variables are = null
    – added support for encrypted password dumped on a file (don’t like password in clear text)
    – added date-time in the log file for each event
    – minor cosmetic in the output
    – tested with vsphere 5.5 U1

    1. You could technically pass your Datacenter object name into the cluster variable, then it would grab all the VMs located in that virtual datacenter! Probably the easiest way! You will have to ensure that you perform the HA/DRS enable/disable on both clusters though if you want to do that!

  3. Hi, this is really great! I wonder – is there a way to store the result? for example – if a VM can’t be shut down for whatever reason, is there some kind of output that can be stored in the log?

    1. I’m sure there is! I’ve been through a few iterations of this script and have a lot of notes and changes I’d like to make upon my next! I’ll be sure to keep that in mind! Thanks!

Leave a Reply

Your email address will not be published. Required fields are marked *