How to install an APC Back-UPS RS 800 UPS on Ubuntu 10.04 LTS

Posted in "News"Ubuntu APC UPS battery

image 2 image 1

This week I had to install an APC Back-UPS RS 800 UPS on a web server at my work. I never done this before so I had to take the APC and Ubuntu manual to do this. Since this type of UPS could be used on your home network or even a small office network I thought it would be interesting to post the steps I have taken to get it installed, it might help someone out. For those who want to know what an UPS does, here we go: An UPS or Uninterruptible Power Supply is a device that helps you to protect your hardware and data when a power-loss or fluctuations occur on the net-current. Depending on the batteries used in the UPS, it can let you run your server for 30 minutes or even longer during a powerloss. When the batteries are almost empty, the UPS sends a "shutdown" signal to your server. 


1. Installing the UPS hardware 

Installing the device is quite easy, just follow the installation manual that is delivered with your device and your good to go. For the model I have used, I have found all documentation here

After installing and powering on, you should check if Ubuntu is able to see the connected UPS, enter following command in the terminal: 


As result you should see the UPS listed between the other USB devices.

Bus 007 Device 002: ID 051d:0002 American Power Conversion Uninterruptible Power Supply


2. Installing the UPS software. 

To be able to monitor your UPS, you need to install the APC software, for windows this is Powerchute, for Linux it means compiling, but luckily Ubuntu has a software packet ready in the repository, called Apcupsd. Just enter following command in the terminal to install it: 

sudo apt-get install apcupsd apcupsd-cgi

After installing, we need to set a value to yes in the Apcupsd-devel internal configuration, edit /etc/default/apcupsd: 

sudo nano /etc/default/apcupsd

And set the ISCONFIGURED value to "yes". 


Be sure to save properly! 


3. Configuring the UPS software.

We need to adjust the configuration to our needs, so start with editing the configuration file: 

sudo nano /etc/apcupsd/apcupsd.conf

find following lines and change them to the values below: 


Save the changes and start the UPS software: 

sudo apcupsd start

You can check the UPS status using this command: 

sudo apcaccess status

The status of the device should show up in your terminal like this: 

APC      : 001,044,1112
DATE     : Fri Oct 07 12:31:27 CEST 2011
HOSTNAME : ecgohd
VERSION  : 3.14.6 (16 May 2009) debian
CABLE    : USB Cable
MODEL    : Back-UPS BR  800
UPSMODE  : Stand Alone
STARTTIME: Wed Oct 05 17:29:17 CEST 2011
LINEV    : 234.0 Volts
LOADPCT  :  19.0 Percent Load Capacity
BCHARGE  : 100.0 Percent
TIMELEFT :  41.2 Minutes
MBATTCHG : 5 Percent
MINTIMEL : 3 Minutes
MAXTIME  : 0 Seconds
OUTPUTV  : 230.0 Volts
SENSE    : Low
DWAKE    : 000 Seconds
DSHUTD   : 000 Seconds
LOTRANS  : 188.0 Volts
HITRANS  : 269.0 Volts
RETPCT   : 000.0 Percent
ITEMP    : 29.2 C Internal
BATTV    : 27.6 Volts
LINEFREQ : 50.0 Hz
LASTXFER : Low line voltage
XONBATT  : Thu Oct 06 16:23:38 CEST 2011
TONBATT  : 0 seconds
CUMONBATT: 7 seconds
XOFFBATT : Thu Oct 06 16:23:45 CEST 2011
STATFLAG : 0x07000008 Status Flag
SERIALNO : <serial-number_of_your_device>
BATTDATE : 2001-09-25
NOMOUTV  : 230 Volts
NOMINV   : 230 Volts
NOMBATTV :  24.0 Volts
NOMPOWER : 540 Watts
FIRMWARE : 9.o5 .I USB FW:o5
END APC  : Fri Oct 07 12:31:29 CEST 2011

If an error occurs you can check the logfile: 

sudo tail -f /var/log/apcupsd.events


4. Using the UPS webapplication.

After installing the software you need to restart your Apache server to activate the webstatus "apcupsd-cgi" of your UPS: 

sudo service apache2 restart

You can check the status using following link: 

Article was posted on Friday 7th of October 2011 @ 17:08 PM CEST   comment(s)