Invite a Co-worker
Send a co-worker an invite to the Exchange portal.Just enter their email address and we’ll connect them to register. After joining, they will belong to the same company.
Send Invite Cancel
80650members
346623posts

How to have single UPS shutdown multiple servers?

Solved
nappyjim_apc
Crewman
Crewman
0 Likes
13
3293

How to have single UPS shutdown multiple servers?

This was originally posted on APC forums on 7/15/2008


My boss has me looking at a new UPS to power about 5 servers. I already ran the little configuration tool APC has and picked out a UPS. Problem is, it only has a single USB connection. I NEED to have all 5 servers be able to shutdown gracefully if we have a power failure. Can I simply plug a USB hub into the UPS and connect my 5 servers to the hub? Does APC sell an add-on? Do they have reasonably prices UPS' with 5 or more USB connections?

Thanks for the help guys.


Accepted Solutions
robin_waarts_apc
Crewman
Crewman
0 Likes
0
3293

Re: How to have single UPS shutdown multiple servers?

This was originally posted on APC forums on 2/4/2009


Hi,

We are using one UPS and serveral servers at the office, one server will be the server for the UPS and the other get te status from that server.

We have four linux and two windows servers (and the switch offcourse) connected to the UPS and using www.apcupsd.org to take care off the turning off.

One linux server is connected with a serial connection to the UPS and the other servers poll the UPS status from that one server.
It is even possible to reboot the server without turning all others off..

Robin

See Answer In Context

shawnpatt_apc
Crewman
Crewman
0 Likes
0
3293

Re: How to have single UPS shutdown multiple servers?

This was originally posted on APC forums on 2/5/2009


Here is how I did it... My server that my UPS is connected to is a Windows 2003 server machine and the desktop that is also connected to the same UPS is a Vista box. This should also work if the machine that the UPS is connected to is a Windows XP machine.

Open notepad and navigate to C:\Program Files\APC\PowerChute Business Edition\agent\cmdfiles

Open the file default.cmd (or create a new file e.g. remshut.cmd)

Insert the following: @START "" "c:\Windows\system32\shutdown.exe" /s /t 10 /m \\server1 (where the /t 10 says wait 10 second on the remote machine and \\server1 is your remote machine that you want to shut down) and save the file

Go to Control Panel -> Services and right click on the APC PBE Agent service and choose Properties

Click on the "Log On" tab and select a user that has administrative rights on the secondary system. I created a new user with matching username and passwords since I am not running in a domain. Remember that if you need to change the password that you have to do it on all of the systems manually. The account should also be set for "Password Never Expires".

Restart both the APC PBE Agent and APC PBE Server services

Open PowerChute and go to Shutdown -> Shutdown Sequence and click the Configure Shutdown Sequence link

Use the dropdown to select your cmd file and then click Test and Yes **This WILL shut down your remote system if everything is working properly, so be prepared.**

I am running this in a home office environment and all of my networking gear is also protected on a UPS, just remember that if you don't have a network this method isn't going to work.

See Answer In Context

kbreiner_apc
Crewman
Crewman
0 Likes
0
3293

Re: How to have single UPS shutdown multiple servers?

This was originally posted on APC forums on 1/16/2009


i picked a winna,

The powerchute software does not have the feature; that's exactly the point. I will need to create it. Simplisticly, it would work kind of like this:

-Power outage occurs
-UPS sends a signal to the connected server over USB that a power outage has occurred.
-After a designated time interval, server then triggers a batch script, which sends shutdown command over ethernet to other PC's.
-Server shuts itself down

Does that make sense? This would thus eliminate the need for purchasing a network card for the UPS. The network card in the server is used instead.

See Answer In Context

13 Replies 13
robin_waarts_apc
Crewman
Crewman
0 Likes
0
3294

Re: How to have single UPS shutdown multiple servers?

This was originally posted on APC forums on 2/4/2009


Hi,

We are using one UPS and serveral servers at the office, one server will be the server for the UPS and the other get te status from that server.

We have four linux and two windows servers (and the switch offcourse) connected to the UPS and using www.apcupsd.org to take care off the turning off.

One linux server is connected with a serial connection to the UPS and the other servers poll the UPS status from that one server.
It is even possible to reboot the server without turning all others off..

Robin

Stew-2_apc
Ensign
Ensign
0 Likes
0
3293

Re: How to have single UPS shutdown multiple servers?

This was originally posted on APC forums on 2/5/2009


This takes about a minute (if you're taking your time) to make a batch file to do this. Like someone else mentioned, use the shutdown command. You can shut down as many remote computers as you want this way.

All you need to do is have the computer which is managing the UPS execute a batch file via the Command File Enabled setting in Powerchute, that batch file would contain the shutdown commands to shut off the remote computers. No extra software required, the remote computers do not need to be aware of the UPS, no network management card needed.

Stew

shawnpatt_apc
Crewman
Crewman
0 Likes
0
3294

Re: How to have single UPS shutdown multiple servers?

This was originally posted on APC forums on 2/5/2009


Here is how I did it... My server that my UPS is connected to is a Windows 2003 server machine and the desktop that is also connected to the same UPS is a Vista box. This should also work if the machine that the UPS is connected to is a Windows XP machine.

Open notepad and navigate to C:\Program Files\APC\PowerChute Business Edition\agent\cmdfiles

Open the file default.cmd (or create a new file e.g. remshut.cmd)

Insert the following: @START "" "c:\Windows\system32\shutdown.exe" /s /t 10 /m \\server1 (where the /t 10 says wait 10 second on the remote machine and \\server1 is your remote machine that you want to shut down) and save the file

Go to Control Panel -> Services and right click on the APC PBE Agent service and choose Properties

Click on the "Log On" tab and select a user that has administrative rights on the secondary system. I created a new user with matching username and passwords since I am not running in a domain. Remember that if you need to change the password that you have to do it on all of the systems manually. The account should also be set for "Password Never Expires".

Restart both the APC PBE Agent and APC PBE Server services

Open PowerChute and go to Shutdown -> Shutdown Sequence and click the Configure Shutdown Sequence link

Use the dropdown to select your cmd file and then click Test and Yes **This WILL shut down your remote system if everything is working properly, so be prepared.**

I am running this in a home office environment and all of my networking gear is also protected on a UPS, just remember that if you don't have a network this method isn't going to work.

BillP
Administrator Administrator
Administrator
0 Likes
0
3293

Re: How to have single UPS shutdown multiple servers?

This reply was originally posted by Matt on APC forums on 7/15/2008


Greetings,

Given you would like to gracefully shutdown 5 servers with one Smart-UPS, you would need to add this functionality via additional hardware. The Smart-UPS alone cannot communicate with more than one PC at a time. Each computer needs a communication path back to the Smart-UPS to receive UPS status information. This can be accomplished by using serial cables or your existing ethernet network. I've outlined the options below:

*1-8 Computers via Serial*: [AP9207 Share-UPS Interface Expander|http://www.apc.com/resource/include/techspec_index.cfm?base_sku=AP9207]. This device plugs into your Smart-UPS' built-in serial port and provides connectivity for up to 8 computers to be shut down via PowerChute Business Edition agents. Cables are not included. You would use this solution if you need to shutdown more than 3 computers. In my opinion, if you need to shut down more than 3 computers, you would want to go with this next option...

Recommended_, 1+ Computers via Ethernet: [Network Management Card|http://www.apc.com/resource/include/techspec_index.cfm?base_sku=AP9617] (now standard equipment in many Smart-UPS). By installing a network management card in your Smart-UPS accessory bay, you give the UPS a presence on your network. It would be reachable by several methods such as HTTP and TELNET, or their secure counterparts HTTPS and SSH. With this card installed, you would no longer use any USB or serial cables for UPS to PC communication. Instead, you would simply use your existing ethernet network and [PowerChute Network Shutdown|http://www.apc.com/resource/include/techspec_index.cfm?base_sku=SFPCNS223&tab=Software]. Unlike with the AP9607CB Expander Card, the AP9617 Network Card does not limit you to 3 computers. You can shut down as many computers as your UPS can safely support.

PCNS is similar to the PowerChute Business Edition Agent component. The PCNS service runs in the background and maintains communication with the UPS's network card. By default, when the UPS reaches the low-battery state, the PCs running PCNS will begin to gracefully shutdown. There are many more customization options for shutting down computers in the PCNS web interface.

You can read more about these options in [kBase # 1141: Shutting Down Multiple Servers From A Single Smart-UPS|http://nam-en.apc.com/cgi-bin/nam_en.cfg/php/enduser/std_adp.php?p_faqid=1141].

The network card option is recommended due to the ease of deployment, the lack of additional cabling, and cost/feature set.

Do either of these options seem to be good match for your configuration? Please let us know if we can assist you further.

bfrawley_apc
Crewman
Crewman
0 Likes
0
3293

Re: How to have single UPS shutdown multiple servers?

This was originally posted on APC forums on 7/31/2008


You could also use a command file to shutdown the servers remotely. You can use the "shutdown" command to shutdown the remote servers. To turn the server back on automatically you can enable Wake On LAN on your servers and use a WOL utility and write a script to power the servers back up.

kbreiner_apc
Crewman
Crewman
0 Likes
0
3293

Re: How to have single UPS shutdown multiple servers?

This was originally posted on APC forums on 1/15/2009


'Sorry for jumping into this thread late. I'm just wondering why APC does not include the ability to shutdown multiple computers connected to a single UPS via a USB or serial connection. Why do you need an NMC? Bfrawley, if what you are saying is true, and it's rather simple to create a script to shutdown connected PC's, why hasn't it been done already? The only thing I can think of is that APC would like to sell more network cards to all of us.

I have an SUA1500RM2U connected to 3 PC's, but it did not include a network managment card. I'm not really eager to spend money on a feature that, in my opinion, should be included with the UPS or in the software.

BillP
Administrator Administrator
Administrator
0 Likes
0
3293

Re: How to have single UPS shutdown multiple servers?

This reply was originally posted by Angela on APC forums on 1/15/2009


hi karl,

i understand what you are saying.

i cant say this with 100% certainty but here is what i am guessing with what I do know:

the smaller VA UPSs do not come built with network management cards (or multiple USB or serial ports for graceful shutdown, etc) because in the vast majority of circumstances, the smaller UPSs arent designed to handle multiple servers because it would theoretically be overloaded since servers are beefier than your averge computer.

also, if this hardware was built in as you suggested, when multiple server configurations on the smaller VA UPSs are in the minority, i believe it would drive up the cost of the unit for those who may not even use the feature for reasons mentioned above. thus, it is provided as an option on the smaller UPSs but is built in for the larger ones. the larger VA UPS systems come with them built in and the cost is bundled into them since the feature will be more useful for larger units which can support higher loads.

hope this helps.

kbreiner_apc
Crewman
Crewman
0 Likes
0
3293

Re: How to have single UPS shutdown multiple servers?

This was originally posted on APC forums on 1/15/2009


That is probably true from a hardware standpoint, but I still see no reason why it could not be included as a feature in the software. It seems that the PCNET protocol runs over IP, so what difference does it make if the shutdown signal is sent from a NIC in the UPS itself, or from a PC connected to the UPS? That's all I'm saying...

I'll probably take bfrawley's suggestion and create my own script to do the shutdown, although I'm not a great programmer.

BillP
Administrator Administrator
Administrator
0 Likes
0
3293

Re: How to have single UPS shutdown multiple servers?

This reply was originally posted by Angela on APC forums on 1/16/2009


you lost me.

the UPS itself has no network connection so how would it send a command to the powerchute network shutdown software over the network without the management card (or thus built in network connection). it would need to have a physical connection to the server which is where powerchute business edition comes in.

it all leads back to hardware requirements with the UPS in my opnion.

kbreiner_apc
Crewman
Crewman
0 Likes
0
3294

Re: How to have single UPS shutdown multiple servers?

This was originally posted on APC forums on 1/16/2009


i picked a winna,

The powerchute software does not have the feature; that's exactly the point. I will need to create it. Simplisticly, it would work kind of like this:

-Power outage occurs
-UPS sends a signal to the connected server over USB that a power outage has occurred.
-After a designated time interval, server then triggers a batch script, which sends shutdown command over ethernet to other PC's.
-Server shuts itself down

Does that make sense? This would thus eliminate the need for purchasing a network card for the UPS. The network card in the server is used instead.

BillP
Administrator Administrator
Administrator
0 Likes
0
3293

Re: How to have single UPS shutdown multiple servers?

This reply was originally posted by Mikhail on APC forums on 1/16/2009


Yes, you right. But please look a bit deeper.
If UPS has a USB port and this is the only way to send signals to a didicated server, then how the signals will be sent to others?

You are right that a script is needed and it is possible to run it from PCBE agent when requried.
However, many IF & THEN can happen with servers and the work strategy which you or your boss would like to have. So it will be more simple to put standard solutions as above.

On the other hand, I would estimate the cost of down time of your servers in case a mistake happens or the first server with the sript fails. I suppose that other 4 servers will not get the commands to shutdown safely. There will be a certain risk you have to accept

I could add more and more things to consider...

BillP
Administrator Administrator
Administrator
0 Likes
0
3293

Re: How to have single UPS shutdown multiple servers?

This reply was originally posted by Angela on APC forums on 1/16/2009


yes, you can do that but as e7e5 said, the physical connection only lets you do the shutdown command to one dedicated server (which isnt a limitation of the software).

dreamaxx_apc
Cadet
0 Likes
0
3293

Re: How to have single UPS shutdown multiple servers?

This was originally posted on APC forums on 4/1/2014


Hey can you confirm how to do this on a windows 7 computer? Do I add a new line with @START "" "c:\Windows\system32\shutdown.exe" /s /t 10 /m \\server1

Above or below the original?