Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

[Solved] Can't get APC UPS to trigger shutdown via 9-pin serial port.

Featured Replies

UnRAID 5.0b2

APCUPSD 3.14.3 (although I've tried 3.14.8 )

UPS: BackUPS 600

Serial cable wired per http://www.nullmodem.com/ups.htm     1:4, 4+9:5 and 2:8

options set to (via UnMENU pkg installer)

Use Serial Port: YES

Cable type: smart (tried dumb)

Syslog attached.

DO NOT know if/how the serial port's being seen by O/S.  Serial port is on PCI card (no DB9s on M/B)

 

Any advice appreciated! Sooo tired of coming home to find server running parity checks because outage outlasted UPS.

I'm having a similar problem, and I think I may be closer to a solution, having found this little nugget

# UPSCABLE <cable>

#  Defines the type of cable connecting the UPS to your computer.

#

#  Possible generic choices for <cable> are:

#    simple, smart, ether, usb

#

#  Or a specific cable model number may be used:

#    940-0119A, 940-0127A, 940-0128A, 940-0020B,

#    940-0020C, 940-0023A, 940-0024B, 940-0024C,

#    940-1524C, 940-0024G, 940-0095A, 940-0095B,

#    940-0095C, M-04-02-2000

 

Notice, it doesn't say "dumb" is an option for cable type. Now, that is documentation for an OLD version of apcupsd, so maybe the newer version has that option, but I couldn't get it to accept it. I am currently running with the option "simple", and it loads apcupsd, but the status never shows power failure, it always shows "OK". I'm going to try actually putting the APC cable number in when I get a chance. Here is another link that discusses cable types. http://www.fatblokeracing.org/ApcupsdCableConfiguration.shtml

 

Jonathan

One fact, apparently not well known, is that APC do not use standard pinning on their connectors, so a regular null-modem cable will NOT work.

 

I cannot check it myself (my UPS has USB and serial on a 10 way RJ style connector) but the pinout is given here...  

 

http://lists.alioth.debian.org/pipermail/nut-upsuser/2005-August/000118.html

 

http://www.everythingtech.net/2009/04/apc-smartups-serial-cable-pinout/

 

Edit: Not sure if this helps having just re-read the original post and link

One fact, apparently not well known, is that APC do not use standard pinning on their connectors, so a regular null-modem cable will NOT work.

If you follow the link the original author posted, he is using the equivalent of the APC 940-0020B cable, NOT a null modem cable. I haven't tested this yet on mine, but I suspect putting 940-0020B in the cable type for apcupsd should work.

Yeah - just saw that and edited my post as you entered yours.  Thanks for the correction.

  • Author

Changed field to "940-0020B", and upon installation, it did report that it was changing to BackUPS....so it *may* be communicating now.  Went into 'UPS Status' in unMenu and see the following:

 

(from /sbin/apcaccess status)

APC      : 001,013,0353

DATE     : Fri Apr 08 19:46:59 EDT 2011

HOSTNAME : Tower

RELEASE  : 3.14.3

VERSION  : 3.14.3 (20 January 2008) slackware

UPSNAME  : Tower

CABLE    : APC Cable 940-0020B

MODEL    : BackUPS

UPSMODE  : Stand Alone

STARTTIME: Fri Apr 08 19:33:32 EDT 2011

LINEFAIL : OK

BATTSTAT : OK

STATFLAG : 0x07000008 Status Flag

END APC  : Fri Apr 08 20:00:46 EDT 2011

 

Additionally, when I go into 'PCI Devices' in unMenu, I see the following:

 

03:06.0 Serial controller: Systembase Co Ltd Unknown device 4d01 (rev b0) (prog-if 02 [16550])

Subsystem: Systembase Co Ltd Unknown device 4d01

Flags: 66MHz, medium devsel, IRQ 21

I/O ports at e800

I/O ports at e400

Capabilities: [40] Power Management version 3

 

I've currently got the UPS discharging (with server bypassing UPS) just to see if it can trigger a shutdown.  

(Triggered UPS with outlet strip- to maintain its connection to common ground reference)

Not optimistic since I've not seen any entries updating onscreen in unMenu main screen...

LINEFAIL : OK

BATTSTAT : OK

 

That is exactly the result I got when I changed to "simple". It seemed to communicate, but not update status. I'll be interested to know what happens when the UPS battery dies, to see if the status lines ever change. BTW, plugging one of those halogen work lights into the UPS makes a dandy fake load to accelerate the process. Just make sure you have enough watts to run the light. :) Perhaps a couple table lamps would be a more accurate load.

  • Author

Apparently the "info" is useless.  The UPS is dead- or at least it's dropped the 100w lamp and is currently continually toning, yet below is the response I get onscreen.

 

(from /sbin/apcaccess status)

 

APC      : 001,013,0353

DATE    : Fri Apr 08 19:46:59 EDT 2011

HOSTNAME : Tower

RELEASE  : 3.14.3

VERSION  : 3.14.3 (20 January 2008) slackware

UPSNAME  : Tower

CABLE    : APC Cable 940-0020B

MODEL    : BackUPS

UPSMODE  : Stand Alone

STARTTIME: Fri Apr 08 19:33:32 EDT 2011

LINEFAIL : OK

BATTSTAT : OK

STATFLAG : 0x07000008 Status Flag

END APC  : Fri Apr 08 21:14:51 EDT 2011

Great... :(

I was hoping changing the cable type would do something productive.

 

Now I'm wondering if simple mode is broken in the apcupsd build that was prebuilt for unraid. Especially since the "documentation" suggests using "dumb" as the cable type.

 

Is there a list of confirmed working with unRaid APC UPS models somewhere?

 

Jonathan

I am not aware of a confirmed list.

 

I have Back-UPS 800 which works very well (detects mains fail and restore and will shut down cleanly and restart for longer outages).  Status report looks like this...

 

UPS Status

(from /sbin/apcaccess status)

APC      : 001,045,1145
DATE     : Sat Apr 09 09:15:56 UTC 2011
HOSTNAME : Tower
RELEASE  : 3.14.3
VERSION  : 3.14.3 (20 January 2008) slackware
UPSNAME  : Tower
CABLE    : Custom Cable Smart
MODEL    : Back-UPS BR  800 
UPSMODE  : Stand Alone
STARTTIME: Sat Mar 26 23:48:13 UTC 2011
STATUS   : ONLINE 
LINEV    : 246.0 Volts
LOADPCT  :   9.0 Percent Load Capacity
BCHARGE  : 100.0 Percent
TIMELEFT :  66.5 Minutes
MBATTCHG : 10 Percent
MINTIMEL : 5 Minutes
MAXTIME  : 300 Seconds
OUTPUTV  : 230.0 Volts
SENSE    : High
DWAKE    : 000 Seconds
DSHUTD   : 000 Seconds
LOTRANS  : 194.0 Volts
HITRANS  : 264.0 Volts
RETPCT   : 000.0 Percent
ITEMP    : 29.2 C Internal
ALARMDEL : Always
BATTV    : 27.1 Volts
LINEFREQ : 50.0 Hz
LASTXFER : Low line voltage
NUMXFERS : 3
XONBATT  : Sat Apr 09 01:23:20 UTC 2011
TONBATT  : 0 seconds
CUMONBATT: 110 seconds
XOFFBATT : Sat Apr 09 01:23:28 UTC 2011
SELFTEST : NO
STATFLAG : 0x07000008 Status Flag
SERIALNO : 3B0951X24834  
BATTDATE : 2001-09-25
NOMOUTV  : 230 Volts
NOMINV   : 230 Volts
NOMBATTV :  24.0 Volts
NOMPOWER : 540 Watts
FIRMWARE : 9.o5 .I USB FW:o5 
APCMODEL : Back-UPS BR  800 
END APC  : Sat Apr 09 09:16:48 UTC 2011

So far the only APC units I have seen posted to work (including yours) with unRaid are smart signaling units. Which is why I made the comment that perhaps simple mode is broken in our prepackaged distribution.

I've used a Bak-Ups 725 via Ethernet. And a 750 via USB. I'm sure that the 725 would work via USB as well.

I've used a Bak-Ups 725 via Ethernet. And a 750 via USB. I'm sure that the 725 would work via USB as well.

Are they reported as smart or simple?

I've solved my issue by bypassing it totally. :'(

 

I hooked my dumb back-ups 500 to a windows machine that also stays on 24-7, and the windows version of apcupsd sees it just fine, and the net option works ok on my unRaid box.

 

I gave up getting the simple signalling option working in unRaid, but I have a suspicion on what the problem could be if others want to continue hammering at it. The installation script only allows very limited editing options of the .conf file for apcupsd, and I suspect manually changing it to the correct cable and ups type might work.

  • Author

I solved my issue by GIVING UP.   >:(

 

Apparently the claim that;

Apcupsd can be used for power management and controlling most of APC's UPS models on Unix and Windows machines.

Apcupsd works with most of APC's Smart-UPS models as well as most simple signalling models such as Back-UPS and BackUPS-Office.

 

isn't valid for a BackUPS 600 or a SmartUPS 620.  NEITHER worked for me. 

The BackUPS did nothing. 

The SmartUPS gave me "Error contacting host localhost port 3551: Connection refused"

 

I've lost too much sleep over this thing.  This shouldn't be rocket science. 

I guess my server's power-down routine will be a graceful fall [glow=red,2,300]flat onto its face.[/glow]

 

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.