VMware Cloud Community
gudel
Contributor
Contributor

ESX 3.5 and APC Battery

I have an ESX Server 3.5 running on APC 3000VA Smart UPS. How can I make the ESX server to shutdown the guests OS's when the battery is low (and turn it back on when it's running on electrical power)? I only have the USB connector that came with the APC unit.

Tags (4)
0 Kudos
27 Replies
admin
Immortal
Immortal

I hear that people have only managed to get it working with a serial question - this is an intersting thread..

0 Kudos
patrickds
Expert
Expert

To be able to shut down the ESX and guests, you'll need the APC Powerchute software.

The only version that is currently supported on ESX is 'Powerchute Network Shutdown', which requires adding a network module to your UPS and connecting it to your network.

Normally, every APC UPS has a serial connection (are you sure yours doen't? maybe the serial cable just got lost)

If you want to use that, you'll have to attach it to another server (or even a VM using serial passthrough; but you will be unable VMotion this VM), and you can use a shutdown script to stop the (other) VMs and the ESX host.

USB will definitely not work (unless it's on another physical system), since there is no software available from APC that can do this on ESX, and you cannot map USB devices to a VM.

There may be third party tools that can make serial or even USB work on the ESX host itself, but i doubt any of those would be supported, and i would not trust to use them on a production system

0 Kudos
gudel
Contributor
Contributor

okay, there's a serial port in the battery backup unit, I'll try to use it. There's no network module on this one, we have one in the older APC.

I saw several Powerchute Network Shutdown version, which one do I use? The only one APC has is for ESX 3.0.2, will this work in 3.5? Is there a walkthrough on installing the utility and setting up the shutdown script?

My other work around is to connect the cable to a separate physical machine and install the APC software there, and install the network shutdown agent on the guests VM's. This will bring down the host hard if the battery runs out.

0 Kudos
asatoran
Immortal
Immortal

At my former company, I used PowerChute Business Edition Basic. It came with the RM1500 units I bought but I think you can download it. You install the program onto a machine that has the cable attached. Then you install the agent program onto the other machines. The cabled machine will send a shutdown command to the machines running the agent..


The version of PowerChute Busines Edition I had could only have 5 agents. I got around that by having my 15 machines on 3 UPS'. That way there was only 5 machines per UPS and per shutdown cable.


I haven't tried this with the cable on the ESX host yet, but if not, if you have any other physical host that you can install the cable, then install the agents on all the VMs.

0 Kudos
patrickds
Expert
Expert

Network Shutdown is only for an APC with network module.

Get the latest version, it is currently supported for ESX 3.0.2, but support for 3.5 will probably follow (this just means they haven't gotten round to testing and certifying it yet)

If you have a network module in another UPS, and don't really need it there (If there is only 1 device using a network agent for that UPS, you can just as easily use serial connection) you could take that out and stick it in the UPS for the ESX host, they should be compatible.

You seem to be mixing things up a bit:

If using serial, you cannot use agents on the VMs. You'll have to install Powerchute Business Edition on 1 machine, either physical or a VM, and setup a script on that machine to shutdown the VMs and the ESX host.

If you're able to use the network module (or buy a new one), you can install Network Shutdown on both the VMs and the ESX host and there's no need for scripts.

Here

http://www.stefanschuller.com/index.php/2007/10/06/guide-how-to-setup-apc-powerchute-network-shutdow...

you can find a nice guide how to instal Network shutdown on your ESX host.

0 Kudos
patrickds
Expert
Expert

You install the program onto a machine that has the cable attached. Then you install the agent program onto the other machines. The cabled machine will send a shutdown command to the machines running the agent..

Are you quite sure?

Maybe this was possible with older versions or another APC software, but currently Powerchute Business Edition requires a cable connection to the UPS from each server you install an agent on.

The agent monitors the UPS and Powerchute Business Edition Server/console are then used to configure shutdowns on the connected agents.

0 Kudos
asatoran
Immortal
Immortal

You install the program onto a machine that has the cable attached. Then you install the agent program onto the other machines. The cabled machine will send a shutdown command to the machines running the agent..Are you quite sure?

Maybe this was possible with older versions or another APC software, but currently Powerchute Business Edition requires a cable connection to the UPS from each server you install an agent on.

The agent monitors the UPS and Powerchute Business Edition Server/console are then used to configure shutdowns on the connected agents.

Yup, quite sure. The only catch is if the Linux version works directly with ESX, which I've never tried. But probably not. Like you said, you'd want the network shutdown. My suggestion would be for a worst case and you install PCBE on any other machine besides ESX, and use that to send a shutdown command to all agents in the VMs.

0 Kudos
trentg
Contributor
Contributor

The only version I can find on the APC site is 2.2.3. The configure script won't run and says the VMware isn't supported. The install documentation says that VMware is supported but only 3.0.x and I have 3.5. The install script finishes fine but I can't configure it. Any ideas?

0 Kudos
patrickds
Expert
Expert

i noticed they changed the install procedure.

I still have 2.2.1, which is an rpm package, the new version is a zipped file and installs using a script.

I know 2.2.1 to work on ESX 3.5, because i've already installed it(using the procedure described in the link i gave earlier) ; not sure about 2.2.3, but normally it should. (might have a problem with the java runtime, according to the release notes)

I'll have to give it a try.

It will be a at least a week before i'm going to the office again, and have my ESX 3.5 test system available, i'll get back to you when i've tried.

0 Kudos
patrickds
Expert
Expert

i just installed ESX 3.5 on a VM, to test this PCNS version.

I get the same error "this product does not support VMware", which is kinda weird, since at least ESX 3.0.1 is supposed to be supported.

On the website, you cannot select ESX or Vmware in the OS list for PCNS either, while this was available in the past.

So it looks like APC simply dropped ESX support for their software (although their manual/release notes still have instructions for Vmware in them)

It is starting to look like the only way to get an APC ups connected, would be third party software. ( something was mentioned in a thread some time ago)

If PCNS isn't supported either anymore, it would make no difference if you used somehting else that works.

Or use version 2.2.1 of PCNS, if you can get it somewhere (maybe the CDrom that came with the network module or UPS).

0 Kudos
patrickds
Expert
Expert

I tried using pcns 2.2.3 on ESX 3.0.2 and it gives the same result, while according to the documentation this should be supported.

I opened a support case for this with APC, since i do ESX installations for clients on an almost fulltime basis, and most are using APC upses (or rebranded APCs, like HP ), and UPS support is kind of elementary.

At the moment i'll just keep using pcns 2.2.1.

As this is not supported on 3.5, i might as well look into something else.

www.apcupsd.org is recommended regularly for linux, and i heard of some people using it on ESX as well.

0 Kudos
trentg
Contributor
Contributor

I have an email into APC support and I will be calling them tomorrow as well. We have a support contract with them. If they fail to provide a working version or workaround we planned to try apcupsd. Thanks for trying it on ESX 3.0.2. They clearly have some issues to address. Installing and running the pcns 2.2.3 configure script on an Ubuntu 7.10 machine (not virtual in any way) yields the same BS "This product doesn't support VMware". APC is starting to be a pretty big disappointment. I think the only thing American about my $15k made in Phillipines UPS is the brand name. Also from the install.sh script, "# Grobal Constants". Thanks.

trentg
Contributor
Contributor

Just got off the phone with APC. They acknowledged the issues and said they were working on a new version for ESX. They gave me a link to the older one.

ftp://ftp.apc.com/apc/public/software/unix/linux/pcns/221vmware/

AustinPowers
Enthusiast
Enthusiast

Anyone know if the status has changed on this? A simple shutdown process for ESX 3.5 on APC UPSes would be nice.

0 Kudos
Funtoosh
Enthusiast
Enthusiast

Even I was looking for the solution incase when power went off and I want to shut my VM's prior to my ESX host. Here is what I found from "Tooms"

Actually one of my college wanted to know how this can be done and he has APC power supply. So he also did some research and found that APC have also recently released a version of PowerChute Network Shutdown for ESX 3 which is quite simple to install and configure

0 Kudos
patrickds
Expert
Expert

So is this a newer version than 2.2.1 (the last known to work on ESX)?

The currently available version is 2.2.3, which cannot be run on Vmware.

Through the APC website there is no way to find an ESX compatible version of PCNS.

0 Kudos
trentg
Contributor
Contributor

2.2.1 is it as far as I know. I wish APC would get their ass in gear.

0 Kudos
cschafer
Contributor
Contributor

Thanks. APC sucks. Glad they at least gave you the old version. Thanks for link. If they take it down just drop me a line and I will put it up somewhere.

cschafer@akimeka.com

0 Kudos
rboteler
Contributor
Contributor

We have 2.2.1 and have had a couple of power failures recently.

It looks like it isnt running the script on ESX 3.5, time to look for an alternative solution...

0 Kudos