www.conserver.com |
Zonker's APC UPS Console Clues
It's serial port is rj45. The cable that's there now and currently working is a 940-0024C. I'm just wondering where I can find a pinout to make this work for me. Pinout of APC RJ12 serial cableRJ12 to DB9. Compatible with Rack PDU (AP78xx, AP79xx, AP86xx, AP88xx, AP89xx) and 2G Rack Automatic Transfer Switches (AP7752, AP7752, AP7730, AP7732, AP7721, AP7723). APC part # 940-0144A.
http://www.conserver.com/consoles/Clues/cons-apc.html
(updated:Jul 14, 2011, 09:26 am)
(updated:Jul 14, 2011, 09:26 am)
I've been a happy UPS user for many, many years now, both at homeand at work. I learned from the mistakes of others, and I've got acollection of UPSs protecting my home equipment, and the Console Lab.While I've worked with a few different vendors, I've got a preferencefor the units from American Power Conversion (APC), because many unitshave serial ports and they can report about the condition of the powercoming into the UPS. I find this information invaluable, but the APCserial interface is NOT directly (i.e. 'pin-for-pin') compatible withthe 'de-facto' DE-9RS-232 serial interface. This page is intended to share information Ihave found about the APC interface, and to explain how to connect thisuseful interface to your console servers. (I've also used the SNMPmodules for the SmartSlot interfaces on older Matrix series units, butthis page will not cover the use of SNMP over Ethernet conenctions.)
The APC Smart serial interface
RJ-45 Console Server Cable Diagrams
Useful off-site URLs
Serial Port Settings
Author Credits
APC SmartUPS Console Signals
The signals for the APC SmartUPS series UPSs is shown at the right. You probably noticed first that there are no handshaking and flow control leads. You probably presumed that the ground and data leads were on the 'normal' pins. Surprise! Notice the other, non-data pins again... the Low Battery and the No AC Input output signals could be used to drive an alarm system, and you could wire your own 'Big Red Switch' if you like, using the Power Off command input signal. (Or even a 'Big Green Switch', but that's outside the scope of this page.) In short, you only need a 3-wire connection between the APC UPS console; transmit and receive data and ground only. |
APC supplies a specialserial cable with each UPS that has a serial console, because their interfacedoesn't match the de-facto standard initially used on the old IBM PC-AT. I recommend that you mark the cable, and hang onto it.
If you use either a 'straight-through', or a 'null-modem' DE-9 cable to connect an APC UPS to a 'normal' DE-9 interface, the UPS will see signals from the attached device. This is why you need a specialty cable or adapter. In the case of the DTE cable (at right), the TD signal from the attached devices will cause the APC to shut off power to the UPS outlets immediately, and you won't be able to command it on with the front panel switches, until you disconnect the cable from the UPS or the host. |
Specialty adapters for Console Servers
If you want to connect the UPS to a console server, I'dsuggest making a special adapter to connect withyour particular console server RJ-45 wiring scheme.
While you could make a specialty cable to go directly fromyour console server to the UPS, my suggestion is to make an RJ45-to-DE9adapter. While you can argue that adding an adapter to the chain willadd one more possible point of failure (for communications between the UPS and the console server), I'll counter with these points;
- the risk is small, especially if the adapter is screwedonto the DE-9 of the UPS
- you can use a stock CAT-3 or CAT-5 cable to conect theadapter to your console server
- using an adapter on the UPS will allow you to connect theUPS quickly toanother device for diagnostics, if that becomes necessary. (Forexample; using an APC diagnostic or configurationtool on a laptop, forinstance, and then reconnecting to the console server for monitoring.)
In the end, the decision is yours. My diagrams show anRJ45 female connection for building the adapter. You can use the samepinouts and use an RJ45 male if you are going to make a direct cable.(If you choose to make a cable, I suggest using an 8-wire cable, sothat the RJ45 male slug will hold the cable securely, and cut theunused leads at the DE-9 end of the cable.)
For a console connection (two-way data), you only need toconnect the signals shown as solidblack lines.(And 'nc' stands for 'No Connection', so no pin number is given.) Thepink dashed lines on the APC UPS output leads are only needed if youare going to try to use the flow control and handshaking inputs of theconsole server to track these signals.
Make Sure YouLABEL Your Adapter (or cable), so others will know whichRJ45 wiring scheme is in use! The Brother label maker folks has some'strong adhesive' versions of their TZ-style label tapes, and they areexcelent for this purpose.
Other sources of APC information
The Internet is a 'fluid' place, and I don't knnow how longeach of the URLs below will last. I've included summary information foreach link, so you can try to search for the pages if the link(s) seembroken.
There is an application, for use with Linux OS machines,called apcupsd,and the project had pointers to some useful How-To pages which have evolved into a good on-line manual, includingpointers to cabling information, and a useful demo page. Their testing apcupsd page also has some useful colues to make sure your second-hand UPS is configured properly.
Remember,if you are testing your UPS, you want the computer/device you arecontrolling/monitoring from to be on independent power, so you don'tshut off your monitor accidentally!
The apcupsd on-line manual has a section that explains which UPS types use the APC Smart protocol, and the APC smart protocol page has clues for the serial communications itself, for the application-side hackers.
The Redhack.org site has a few older pages that discuss the APC cabling (deeplink)for various APC UPSs, in relation to early versions of apcupsd.
There is also a useful pinouts page in russia (pinouts.ru)with a UPS section that includes APC (Smartand dumb) as well as other vendor's devices. (I was cautiousabout visiting the site, but I've used it a number of times now with nomalware troubles. Use caution anyway...always practice safe hex.)
Besides searching for apcupsd serial cable, you can also look forinformation under NUT (for 'Network UPS Tools') which are available fora few Linux OSs. I found a basic page about using NUT with an APC UPS on engadget
Sperial Port Speeds
(As a Best Practice, always ensure that your physical link is in placebefore you waste time on serial port settins. )
I've run into a few APC UPS ports. They've responded at 2400-8-N-1, butnot at 9600 bps. I've found articles that say to try 19,200 bps, but I haven'tfound any that respond at that speed. I agree that my sample set is relativelysmall, and my not be representative of the majority of APC serial ports deployedto date, but it is my only experience so far.
By all means, if 2400 8N1 doesn't seem to work for you, try other settings.(After you have made sure that your physical link is correct and connected!)
Now that you have a User Name: prompt, try the default apc (with the default password of apc.
Jon Steiger has a good web page for the APC SNMP module,which mentions some different serial speed possibilities, and also discusses APC's password recovery process.
Jeff Liebermann posted some ASCII art cable diagrams, and mentions that some APC SNMP adapters will let you change the serial port speed, but the default is 2400 bps.
APC Remote PDU Serial Console Signals
These signals are derived from my testing of an APC model AP7868 smart PDU. I was able to make a 3-wire connection to a Lantronix ETS32PTR terminal server. There is a small voltage present on the RJ-13 pins 1 and 6. I'm not sure if it is the same voltage bus (maybe just for a pull-up signal?). |
As you can see, there are tidbits of information, and some of it is conflicting. Unfortunately, this page will only add to the mix. Since I didn't find a single 940-0144A cable around a 120-plus PDU installation, I cannot confirm the pinouts shown in these other (offsite) links. However, I will comment on some of the inconsistencies that led me to my experiment;
Armed with enough examples to have a starting point (yes - it is RS-232, there are two possible Ground pins), I then took out my DVM (digital voltmeter) and my Siemon MODAPT, to try to verify signals, and reconcile the differences that I'd read about, using one of our APC model AP7868 PDUs. Here's what I found;
I still need to try to determine if the Ground on RJ-14 Pin 2 is the same as Pin 5. (That is, zero-ohm continuity, or some other resistance/impedance.) I also don't know whether tying RJ-14 Pin 1 and Pin 6 together accomplishes any electrical/logical changes. For now, letting both Pin 1 and Pin 6 float (no connection) has not made a measurable difference for an RS-232 connection. (Other notes in my blog.) This has been tested with the AP7868 rPDU, and I'll have an AP7900 to test soon. |
Specialty cables between the rPDU and Console Servers
(Lantronix Users can use the Cisco Console adapters. So can Opengear users, if your device uses the Cisco wiring schema.)
NOTICE: Most of the pages, articles, and tutorials on this website are copyrighted works. You may make 'deep links' to various pages. (If you let me know which page(s) you are linking to, I'll let you know if I move the page(s) during updates.) Please send me email if you wish to republish any material, or use it on your own website. |
Questions? Comments? Additions? Email consoles atconserver.com.
(Don't harvest my address, I don't wantSPAM!)
How does he do it? AndWhy?