We are updating all our vmWare hosts to be sure that they are correctly shut down using an APC SmartUPS.
At first glance it appears that you need a VMA instance installed on the vmWare box. Then, using Linux commands, install and configure PowerChute Business Edition on the VMA. This will then allow you to connect to the UPS and shutdown the VMs gracefully.
One downside of working this way however is the increased support requirement, additional VM and the resources required to run the additional VM.
So, we have configured our APC SmartUPS with vmWare ESX in a different way…
- Connect the SmartUPS to the vmWare physical box via USB cable.
- Configure vmWare to pass through the USB controller to one of our VM hosts (our SBS Server in this example as it is always on and required for our network).
- Configured vmWare to pass through the APC SmartUPS to the same VM host (our SBS Server).
- Install all 3 parts of PowerChute Business Edition on the SBS server and connected to USB SmartUPS.
- Install Putty (the full installer) on the windows server (SBS server)
- Install (or be sure it is installed) VM Tools on all the VMs on this host.
- Enable the SSH service on the VM Host using vSphere (Configuration -> Security Profile -> Services)
- Set all VMs to ‘Guest Shutdown’
- Create a new file in C:\Program Files (x86)\APC\PowerChute Business Edition\agent\cmdfiles called shutdown_vm.cmd and add content as follows:
CD “C:\Program Files (x86)\PuTTY”
@START plink.exe -ssh -pw <password> email@example.com “/sbin/shutdown.sh; /sbin/poweroff”
- Test the command file manually from a command prompt to be sure that it runs!
Set PowerChute shutdown mode to Preserve Battery (or it won’t run the shutdown schedule!) (maybe?!)
- Set PowerChute Agent Service to ‘interact with desktop’
- Prepare servers for testing (ensure everyone is logged off)
- Edit PowerChute Business Edition shutdown sequence and include command file and select the script shutdown_vm.cmd
- Test the command from the shutdown schedule to be sure all servers in the command shut down properly