stefanschuller.com ___Virtual reality


Guide: how to setup APC Powerchute Network Shutdown in VMware ESX 3
Saturday October 06th 2007, 9:04 pm
Filed under: vmware

At customers I often need to setup ESX servers together with APC UPS devices. this guide describes how to do that.

APC has a guide on how to do this but it doesn’t totally cover the installation for VMware ESX 3.0.x For example it forgets to tell you about the firewall in ESX 3 that blocks some ports that need to be open to make the Powerchute Network Shutdown agent communicate with your APC ups (with network management card option installed)

Assumed:
you have an ESX 3 server running.
You have an APC UPS with a management card that is configured.
The IP address of the ESX server is registered to allow it to communicate with the management card.
You know the login, password and authentication phrase of the UPS management card.

This is a 3 step process

1. Configure the VMware ESX 3 firewall
2. Install the APC Network Shutdown agent
3. Configure the APC Network Shutdown agent

Step 1 - Configure the VMware ESX 3 firewall

Logon to your service console with your favorite ssh client (putty)

open up the firewall with the following commands


esxcfg-firewall -o 80,tcp,out,"APC tcp Port 80"
esxcfg-firewall -o 3052,tcp,in,"APC tcp Port 3052"
esxcfg-firewall -o 3052,udp,out,"APC udp Port 3052"
esxcfg-firewall -o 3052,udp,in,"APC udp Port 3052"

Move to the next step.

Step 2 - Install the APC Network Shutdown agent

Download the “PowerChute Network Shutdown v2.2.1 for VMWare” from the APC website called pcns-2.2.1-100.i386.rpm link(need an account to get it)

copy the file to the ESX service console and run the following command

rpm -ihv pcns-2.2.1-100.i386.rpm

Step 3 - Configure the APC Network Shutdown agent

Run the configuration script command:

/usr/local/bin/PowerChute/PCNSConfig.sh

Now a “wizard” will guide you to configure the agent follow the instructions.

after this you can configure the rest of the setup through a webinterface http://youresxserver:3052

In the event log link you can check if the esx server is communicating with the UPS. It should show a message that it established a connection.

Resource Links
APC install guide link
VMTN forum link (thanks box293)

1 Star2 Stars3 Stars4 Stars5 Stars (10 votes, average: 4.7 out of 5)
Loading ... Loading ...

26 Comments so far
Leave a comment

[…] Check out the detailed instructions at Guide: how to setup APC Powerchute Network Shutdown in VMware ESX 3 […]

Pingback by treesum VM /ETC » Blog Archive » How to use APC Powerchute to shutdown VMware ESX 3 11.18.07 @ 12:08 pm

Thank you for the great instructions. It worked fine for me.
Best regards from Austria, Henry

Comment by Henry 12.22.07 @ 9:28 pm

Thank you very much ,It worked for me. From kyue,china.

Comment by kyue 03.26.08 @ 10:06 am

Does this also work for ESX 3.5?

Regards,
Nikolaj

Comment by Nikolaj7 03.27.08 @ 12:59 pm

Hi,

APC PowerChute Network Shutdown (PCNS) v2.2.1 does NOT support ESX 3.5.

APC are still working on releasing a compatible version, but knowing how slow APC are it may be availble in time for the next release of ESX.

Makka…

Comment by MakkaPakka 04.06.08 @ 2:55 pm

As an update to this, the software is no longer linked from apc.com but it is still on their ftp site. ftp://ftp.apcc.com/apc/public/software/unix/linux/pcns/221vmware

Comment by Jeff 04.11.08 @ 11:10 pm

1. What’s the best way to test/verify PCNS after it’s installed??

2. WRT the firewall changes, I don’t see them in VIC, must I do something else?? (They are only for the web frontend etc.)

Thank you, Tom

Comment by Tom 06.02.08 @ 7:28 am

This is probably a stupid question but I am totally new to the IT field and my boss asked me to research how to shutdown VMware using our APC when power failure happens? I am not at all familiar with VMware and Little more with our APC.
Is this article describing what I wish to do?

Comment by Phll 07.04.08 @ 12:40 pm

Hi Phil, then suggest your boss to hire IT expert :) everybody need a job…

Comment by James 07.12.08 @ 4:56 pm

221 appears to work okay with 3.5. I’ve not fully tested it, but it does appear to work.

223, the current version on the APC site, will not install on ESX 3.5.

Comment by Jon 08.28.08 @ 5:04 pm

can this be used to trigger a guest VM shutdown, or does powerchute need to be installed in the guests as well?

Comment by dennis 10.31.08 @ 7:55 pm

#dennis

Hey Dennis.

If you set up your EXS to shutdonw and startup the guest OS’ in your infrastructure client, it should not be nessesary to install the powerchute on the guests. (testing it while writing this ^^)

Comment by Simon 12.05.08 @ 11:47 am

Version 223 DOES work on ESX 3.5, but the instructions are wrong.

Additional ports need to be opened with versions 223.
Use these commands on the server to configure the firewall.

esxcfg-firewall -o 80,tcp,out,”APC PowerChute Port 80″
esxcfg-firewall -o 3052,tcp,out,”APC PowerChute Port 3052″
esxcfg-firewall -o 3052,tcp,in,”APC PowerChute Port 3052″
esxcfg-firewall -o 3052,udp,out,”APC PowerChute Port 3052″
esxcfg-firewall -o 3052,udp,in,”APC PowerChute Port 3052″
esxcfg-firewall -o 6547,tcp,out,”APC PowerChute Port 6547″
esxcfg-firewall -o 6547,tcp,in,”APC PowerChute Port 6547″

Copy the installation files to /tmp
Forget about decompressing the .gz or the tar. Just run the install routine from the tmp directory (./install.sh)
Accept the defaults

Change to the installation location of the APC software with
cd /opt/APC/PowerChute/group1

Configure the Powerchute server agent with
./PCNSConfig.sh

And it should work.

By the way, the default username and password is ‘apc’, and the default authentication phrase is ‘admin user phrase’ (without the quotes)

It does work very well, but the installation instructions are hopeless. They don’t even mention the firewall. Good luck!

Comment by Paul 12.16.08 @ 11:45 am

How do you run the install script command? ./install.sh is not there.

Comment by mike 12.17.08 @ 12:33 am

I copied the CD to /tmp, here’s a list of the directory:
-rwxr-xr-x 1 root root 76283 Nov 29 2007 install.htm
-rwxr-xr-x 1 root root 27885 Oct 17 2007 install.sh
-rwxr-xr-x 1 root root 27338814 Oct 17 2007 jre150_13_linux.tar.gz
-rwxr-xr-x 1 root root 1819811 Nov 15 2007 pcns223.tar.gz
-rwxr-xr-x 1 root root 16758 Nov 29 2007 relnotes.htm
-rwxr-xr-x 1 root root 877 Dec 25 2006 silentInstall.sample

The ./install.sh is definitely on the CD - I’m looking at it now.

When you copy it to /tmp, make sure it’s executable with the command:
chmod +x install.sh

My CD is labelled “Powerchute Network Shutdown for VMware”, part number 991-0502. There’s no version number on the CD, but Help>About from the server-hosted html page shows “PowerChute Network Shutdown 2.2.3 Build 12″

Comment by Paul 12.17.08 @ 1:51 pm

I just tried this on 3.5 update 3 and it tells me the product does not support Vmware….

Comment by Steven 02.13.09 @ 5:12 am

I have ftp’d in and find 221vmware here,

/apc/public/software/unix/linux/pcns/221vmware

Comment by Steven 02.13.09 @ 5:20 am

I installed PCNS 221 on VMware ESX 3.5,U3. I think its working; services are running & web page is up (http://esxserver:3052). But I cannot login via web page, I tried all the accounts I can think of. What am I missing?

Comment by Juice 03.25.09 @ 11:32 pm

Juice, have you tried the default apc / apc ?

Comment by Toby Henderson 04.17.09 @ 11:14 am

Just tried v223 on ESX 4.0 - didn’t work. I get “This product does not support VMware”.

Comment by Ulrik Andreassen 05.27.09 @ 12:31 am

apc sells a version of pcns for esx; we paid $99 per copy

Comment by p gilman 06.24.09 @ 10:59 pm


I have installed pcns for VMWAre but i can’t login with user/password: apc/apc at
https://server_ipaddres:6547
Does anyone install this sw and make its works?

Comment by Robert 12.22.09 @ 7:29 pm

Is there anyone having the UPS up and running with VMware ESXi?

Comment by Edwin 04.13.10 @ 4:49 pm

work with vmware vsphere 4 update 1 or I need more steps for this version??

Comment by Oscar 04.16.10 @ 12:13 am

Hi, Just tested with vSphere 4u1 and it works perfectly.

Comment by Scott 06.10.10 @ 9:39 pm



Leave a comment

(required)

(required)