SUMMARY: UPS with Solaris 1.x agent

From: David Lawrence Oppenheimer (davido@phoenix.princeton.edu)
Date: Thu Aug 04 1994 - 07:18:05 CDT


Many thanks to those who replied to my question about UPS units for the
Sun. My original query asked for information on UPS units which came with,
or could be used with, software which would shut down a Sun (SS5) running
SunOS 4.1.3 (Solaris 1.1.1). I needed something which would, for example,
execute the 'shutdown' command on the Sun some time before the UPS's
batteries died.

Most of the responses suggested the same four or five products, so I will
provide a sample of the responses and then list the names of those who
provided similar answers but whose full replies I am not quoting.

Before I dive into a rather lengthy summary, I should point out that
Nick Christenson (npc@minotaur.jpl.nasa.gov) maintains a UPS FAQ at
ftp://navigator.jpl.nasa.gov/pub/doc/faq/UPS.faq

--------------------------------------------------------------------

From: Juergen Wagner <gandalf@Csli.Stanford.EDU>
Message-Id: <199407311654.JAA27956@Csli.Stanford.EDU>
To: davido@phoenix
Subject: Re: Q: Want UPS with Solaris 1.x agent
Newsgroups: info.sun-managers
In-Reply-To: <Pine.3.89.9407310821.A6399-0100000@flagstaff.princeton.edu>
Organization: Stanford University

We have recently checked the market to see what UPSs are available for
our file server (120GB HP jukebox, 4 MO drives, several 1-2 GB disks,
tapes, SPARC 10/51 under Solaris 2.3). One of the requirements was
that shutdown and monitoring software must be available for Solaris.

We ended up with SmartUPS 1250 from APC. The software is PowerChute.
SmartUPS 1250 is available (at academic discounts) for about $1000,
Powerchute is an extra $100 (you can use one copy for an arbitrary
number of UPSs).

The reasons why we ended up getting SmartUPS were
o The UPS was relatively inexpensive.
o Same for the software (for one product, the software alone was $500).
o There is a sleep mode, i.e., the battery doesn't drain during downtime.
o The software is primitive but sufficient. It comes for a variety of UNIX
   versions when ordered for UNIX (i.e., you order "UNIX version" and get
   disks for a number of them).
o Shutdown and warnings are issued by scripts executed by the UPS monitor.
   i.e., they can be modified easily to add more actions.
o The UPS itself is compact.

Online UPSs are desirable for larger capacities (5kVA and more), in
the range up to 2kVA, it's usually not necessary because the power
supplies of the connected components are too slow to notice to 2-4ms
switching time, anyway. However, it is important to have
irregularities and small sags filtered out.

The file server I mentioned can run for 20 minutes on battery,
reducing the battery capacity from 100% to 25-30%.

--Juergen Wagner

Juergen.Wagner@iao.fhg.de
gandalf@csli.stanford.edu

Fraunhofer-Institut fuer Arbeitswirtschaft und Organisation (FhG-IAO)
Nobelstr. 12c Voice: +49-711-970-2013
D-70569 Stuttgart, Germany Fax: +49-711-970-2299
For more information/detail, please do "finger gandalf@csli.stanford.edu".

------------------------------------------------------------------------
From: johnrk@bartman.syntellect.com (John Koehring)
Message-Id: <9407311644.AA23342@bartman.syntellect.com>
To: davido@phoenix
Subject: Re: Q: Want UPS with Solaris 1.x agent

David,

My SPARCstation IPX running SunOS 4.1.3_U1 is plugged into a
Smart-UPS 600 from American Power Conversion. The IPX is running
"PowerChute plus" software (also from APC) that allows the IPX and
UPS to converse over a serial line. "PowerChute plus" not only
lets the UPS notify the IPX of a power failure, but also lets
a user on the IPX monitor the operation of the UPS, obtaining
information like current line voltage, current battery capacity,
UPS temperature, and so on.

I like the UPS a lot. The software (version 3.1.3) has a few
bugs but is otherwise pretty good. I have been told by APC that
a new version of the software is due "any day now". APC can be
reached at 1-800-800-4272.

-- john
-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+--+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
John R. Koehring Voice/FAX: 602-967-2365/602-921-7060
309 East La Jolla Drive Internet: johnrk@bartman.syntellect.com
Tempe, Arizona 85282-5325 CompuServe: 74134,1302

-----------------------------------------------------------------------

From: Doug Neuhauser <doug@seismo.berkeley.edu>
Message-Id: <199407312215.PAA12123@perry.geo.berkeley.edu>
To: davido@phoenix
Subject: Re: Q: Want UPS with Solaris 1.x agent
Status: O
X-Status:

Best has UPS units with software for Suns to perform a shutdown.
- Doug Neuhauser, doug@seismo.berkeley.edu, 510-642-0931

--------------------------------------------------------------------------

From: pasken@newton.slu.edu (Robert Pasken)
Date: Sun, 31 Jul 1994 17:28:30 CDT
In-Reply-To: David Lawrence Oppenheimer <davido@phoenix.princeton.edu>
       "Q: Want UPS with Solaris 1.x agent" (Jul 31, 8:23am)
X-Mailer: Mail User's Shell (7.1.2 7/11/90)
To: David Lawrence Oppenheimer <davido@phoenix>
Subject: Re: Q: Want UPS with Solaris 1.x agent

        If you are willing to give up a serial port on the Sparc-5 then there
was an article in Unix World about two years ago that showed how to wire the
serial port to the UPS and then a short shell script that started at boot time
and monitored the UPS through the serial port. It required a $2.00 worth of
parts (RS-232 jack, wire, etc) to build.

RWP

---------------------------------------------------------------------------

From: "Quinlan, Grant W." <gquinlan@mmpc.ssd.lmsc.lockheed.com>
To: David Oppenheimer <davido@Princeton.EDU>
Subject: RE: Q:Want UPS with Solaris 1.x agent
Date: Sun, 31 Jul 94 18:32:00 pst
Message-Id: <2E3C5F0E@mm.is.lmsc.lockheed.com>
Encoding: 23 TEXT
X-Mailer: Microsoft Mail V3.0

We have two SPARC Server 1000 systems that we needed UPS backups for. About
November of '93 we gathered information and quotes from several UPS vendors.
We ended up purchasing two 2000XL systems from American Power Conversion
Corporation in January. The UPS systems are connected to the servers using
the ttyb serial ports (the software defaults to ttya, which we are using for
our consoles, but is easy to change.) A deamon called "powerchute" run on
the servers to
monitor the ttyb port, shutdown the systems when needed, and maintain logs
of voltage and power quality.

The one problem we encountered in using these systems was that the software
we received was on a 3.5" floppy formatted for SUN workstations. We called
APC and they promptly sent us a DOS format floppy with a single tar file
that we FTPed from a PC to the servers. The UPS's have worked
flawlessly for 6 months. We have used the log files to create EXCEL charts
documenting the power problems we've had in our building, which has become
an invaluable tool for identifying the causes of recurring systems failures
in our Air Conditoning Systems and Robotics Systems and justifying
protective measures.

     Grant Quinlan
     Quinlan@ACM.org

--------------------------------------------------------------------------

From: Chris Wozniak TISC <chris@tisc.edu.au>
Message-Id: <199408010219.KAA02323@sun.tisc.edu.au>
Subject: Re: Q: Want UPS with Solaris 1.x agent
To: davido@phoenix
Date: Mon, 1 Aug 1994 10:19:51 +0800 (WST)
In-Reply-To: <Pine.3.89.9407310821.A6399-0100000@flagstaff.Princeton.EDU> from "David Lawrence Oppenheimer" at Jul 31, 94 08:23:28 am
Content-Type: text
Content-Length: 2220

Hi there. Earlier this year we had a mini hurricane and a power failure
that (we believe) contributed to the hard disk crash a couple of weeks
later. We decided to buy a UPS to prevent such accidents in the future.
In our remote Perth I found a galore of outfits selling various brands
of them. ALL of them had a software package recommended to provide
shutdown capabilities. In the end we bought Sola 2000kv UPS, that
came with the PowerMon software (USA, St. Louis, MO) The UPS
was $Aus 2100, the single licence s-ware $Aus 200. The UPS has a 9
pin connector, connected through the serial cable to the /dev/ttyb
port on the Sun server. Software runs as a daemon, watching for the
shorting of pins 2 and 4 (9 DBS), that indicats power failure and battery
backup. Software installation and config is extremaly simple, takes
about 15 mins. There is a number of scripts in the package that can
be customised locally. We have customised it to display our own warning
and shut the other workstations on the net using "rsh".
You should be probably best off shopping around and buying a commercial
package, they are quite cheap.

-- 
Chris A. Wozniak
TISC Inc.
ph.  +61 9 386 8236			e-mail chris@tisc.tisc.edu.au
fax  +61 9 386 6589

-----------------------------------------------------------------------------

From: Matt Reed <reed@cs.swarthmore.edu> Message-Id: <199408010232.WAA00194@allspice.cs.swarthmore.edu> To: davido@phoenix Subject: Re: Q: Want UPS with Solaris 1.x agent Newsgroups: _swat.list.sun-managers In-Reply-To: <Pine.3.89.9407310821.A6399-0100000@flagstaff.princeton.edu> Organization: Swarthmore College Computer Science, Swarthmore, PA, USA Cc: Status: O X-Status:

We have a Tripplite UPS and will be using PowerAlert software to do automatic shutdowns. These items are available from places like Inmac and Unix Central.

Matt Reed Computer Science Dept. Swarthmore College reed@cs.swarthmore.edux

----------------------------------------------------------------------------

From: kes@mtb.phil.mop.com (Kes Masalaitis) Message-Id: <9408011143.AA09956@pepper.phil.mop.com> Subject: Re: Q: Want UPS with Solaris 1.x agent To: davido@phoenix Date: Mon, 1 Aug 1994 07:43:41 -0400 (EDT) In-Reply-To: <Pine.3.89.9407310821.A6399-0100000@flagstaff.Princeton.EDU> from "David Lawrence Oppenheimer" at Jul 31, 94 08:23:28 am X-Mailer: ELM [version 2.4 PL20] Content-Type: text Content-Length: 609 Status: O X-Status:

David,

I have 5 Best Power Technologies UPS systems that connect to a Sun with a serial cable. A daemon runs and starts a script to shut the machine down. It is trivial to modify the script to shut down all the machines attached to the UPS.

Call Keith Holcomb at Best (800)356-5794 and tell him Kes Masalaitis sent you.

Kes - Kes Masalaitis INTERNET: kes@mop.com Cooper Neff Technologies, L.P. UUCP: ...!uunet!mtbphil!kes #3 Radnor Corporate Center PHONE: (215)995-1434 Suite 131 All standard disclaimers apply Radnor, Pa. 19087

-----------------------------------------------------------------------------

Date: Mon, 1 Aug 1994 08:55:44 +0600 From: j_wilder@tolstoy.mdc.com (John T Wilder 312C M 209387) Message-Id: <9408011355.AA01009@chaucer.f18mcsdf> To: davido@phoenix Subject: Re: Q: Want UPS with Solaris 1.x agent X-Sun-Charset: US-ASCII Content-Length: 389

There is a package called PowerMon by Systems Enhancement Corp. Supports IBM AIX, AT&T, SCO, SUN OS and Solaris, DEC Ultrix and VMS, HP-UX, etc. UPS: Liebert

Call Ray Moore for more info... Electronic Support Systems, INC. 3409 Hollenberg Dr Bridgeton, MO 63044 314-739-6400

John Wilder McDonnell Douglas Aerospace F/A-18 Avionics Support 314-233-6329 j_wilder@tolstoy.mdc.com

-----------------------------------------------------------------------------

From: geturner@aer.com (George E. Turner) Message-Id: <9408011333.AA16048@aer.com> To: davido@phoenix Subject: Want UPS with Solaris 1.x agent Content-Length: 518 Status: O X-Status:

We use APC's PowerChute Plus and it works quite well. Once it warned our users to log off, there had been a power failure. The power was only off for a few seconds, so it didn't power down the machines it was on, but it did send out a second message telling everybody that everything was back to normal when the power returned.

You need:

an APC Smart-UPS, a Marix-UPS or Back-UPS.

SCO UNIX, AT&T UNIX, Solaris or SunOS 4.1.x or higher or AIX

1 RS-232 port dedicated to Powerchute and a 3.5" high density floppy

----------------------------------------------------------------------------

Date: Mon, 1 Aug 1994 09:24:27 -0400 From: 25852-goeke <rjg2@dingy.cc.bellcore.com> Message-Id: <199408011324.AA05734@elan.cc.bellcore.com> To: davido@phoenix

David,

Re: UPS for UNIX

Recently I've spent a little time looking at a UPS interface for UNIX called PowerMon by Emerson Computer Power. We are using this product on our Novell network and I'm currently testing the UNIX version.

Here's the address: Emerson Computer Power Liebert Corporation 1050 Dearborn Dr. P.O. Box 29186 Columbus, OH 43229

Tech. Support Number: 1-800-backups

Rick Goeke Bell Communications Research 3 Corporate Place Piscataway, N.J. 08854 rjg2@bellcore.com

---------------------------------------------------------------------------

From: louis@meg.meg.saic.com (Dances on keyboards (Louis Brune)) Message-Id: <9408011312.AA02041@elgar.saic.com> To: davido@phoenix In-Reply-To: <Pine.3.89.9407310821.A6399-0100000@flagstaff.Princeton.EDU> (message from David Lawrence Oppenheimer on Sun, 31 Jul 1994 08:23:28 -0400 (EDT)) Subject: Re: Q: Want UPS with Solaris 1.x agent Content-Length: 483 Status: O X-Status:

A caveat. Some time ago I was testing this sort of equipment. In general, it alleged to provide both a "you're running on batteries" notification, as well as "the batteries are nearly dead". My experience was that we could either, but not both.

Check the return policy of whatever you buy.

Bikes on the road. Cars in the gutter. Louis M. Brune Software Development Facilitator SAIC louis@meg.saic.com 5550 Oberlin Drive 619-453-8200 San Diego, CA. 92121

--------------------------------------------------------------------------

From: mike@trdlnk.com (Michael Sullivan) To: davido@phoenix Subject: Re: Q: Want UPS with Solaris 1.x agent Content-Type: X-sun-attachment Status: O X-Status:

---------- X-Sun-Data-Type: text X-Sun-Data-Description: text X-Sun-Data-Name: text X-Sun-Content-Lines: 18

>I'm looking for a UPS unit which can be connected to a Sun (I'm using an >SS5 and SunOS 4.1.3_U1) and which will do automatic shutdown upon >detecting a power loss. I have seen UPS's advertised in magazines with >interfaces to Novell networks to do this shutdown task, but none >specifically for UNIX. (Perhaps I'm just not reading the right magazines ;-)

We have a couple of MinuteMan UPS's from Para Systems, Inc. on our servers and some of the more important workstations. They provide an indication that the UPS is in power-fail mode through an RS-232-level signal that can be wired to the Carrier Detect input of an unused serial port. I believe some other UPS manufacturers use the same approach.

>If anyone is using a UPS with auomatic shutdown capabilities for SunOS >4.1.3, or has written a script to take the "shutdown" signal from the UPS >and turn in into a, say "shutdown +5" command, please let me know.

I didn't need to write a script, because a suitable program (attached) was published in SunWorld at just about the time we hooked up the UPS. ---------- X-Sun-Data-Type: c-file X-Sun-Data-Name: powerfail.c X-Sun-Content-Lines: 40

/* powerfail utility * adapted from an article by Hal Stern in the April 1992 SunWorld * */ #include <stdio.h> #include <sys/file.h> #include <sys/signal.h>

/* seconds to wait after power fail indication from UPS before * starting shutdown. If power is restored before this time expires * the shutdown will not performed. */ #define DELAY 60

/* explanatory message for shutdown command */ #define MESSAGE "power failure"

main(argc, argv) int argc; char **argv; { int fd; int do_shutdown(); char device[128];

sprintf(device, "/dev/%s", argv[1]); fd = open(device, O_RDONLY); if (fd < 0) { fprintf(stderr, "%s: failed to open %s\n", argv[0], device); exit(1); } signal(SIGALRM, do_shutdown); alarm(DELAY); sigpause(); /* wait for something to happen */ }

int do_shutdown() { execl("/usr/etc/shutdown","shutdown","-h","now",MESSAGE,(char*)NULL); }

------------------------------------------------------------------------------ From: eww@hobbes.crc.com (Eric Wampner ORL) Subject: Re: Q: Want UPS with Solaris 1.x agent To: davido@phoenix Date: Mon, 1 Aug 1994 11:36:57 -0400 (EDT) In-Reply-To: <Pine.3.89.9407310821.A6399-0100000@flagstaff.Princeton.EDU> from "David Lawrence Oppenheimer" at Jul 31, 94 08:23:28 am X-Mailer: ELM [version 2.4 PL23]

from the blub:

Power Alert Unattended Lan Shutdown Accessories

Tripp Lite can safely power down your network during a power outage. Software, cabling, and accessories work with all Tripp Lite UPS series to perform orderly unattended shutdown. All Tripp Lite UPSs are SNMP compatible. Power Alert safely closes Novell, UNIX/XENIX, LANtastic, AppleShare, MS-DOS, Windows, Banyan, and other operating systems. Software and cabling for _any_ network system. Call or write for details and part numbers.

(a bunch of trademarks, including Sun micros)

Customer Service 312-329-1601 Faxback 312-329-9717

Tripp Lite 500 N. Orleans Chicago, Il 60610-4188

Trip Lite makes BC, Omni Power, and Unison MPS series UPS, along with surge suppressors, power strips, and power conditioners.

--------------------------------------------------------------------------

From: dburwell@telecom.telecom.com (David Burwell (7929)) To: davido@phoenix Subject: Re: Q: Want UPS with Solaris 1.x agent Status: O X-Status:

I use the American Power Corp. (APC) UPS'es. I use the APC SmartUPS. The SmartUPS has a serial interface to the Sun and an SNMP option. There is software for the Sun called "Powerchute" that allows you to monitor and make some changes to the UPS.

I use the APC 900XL for an SS2 with 7 harddisks, 2 tape drives, a CDROM and 3 36 port hubs. The "XL" models have a feature that will allow you to add batteries to the existing unit, thereby increasing the time it will deliver its rated output. The APC 900 will deliver 900VA for about 10 to 15 min. The 900XL with 1 battery will do the same, but with 2 will deliver 900VA for 30 min, and so on upto the max num. of batteries (7 I think). There are six regular 110V outlets on the back of the UPS. I had an Electricion wire in some wall outlets on 3 sides of the room where the UPS is, and then I run an extension cord from those circuits back to the UPS. That gives me an additional 12 outlets mounted on the wall next to the equipment that needs it. The UPS needs one 110v AC outlet to run off of.

When there is a power failure, the UPS signals the SS2, the Powerchute software daemon then starts a shutdown script file that will tell all that are logged into that machine that a power failure has occured and it will be shutting down in XX minutes (XX is settable by you from 1 to 99 min.) If the power returns, the script is canceled and everything goes back to normal. At XX min, the script file does a "shutdown -h now" to kill the workstation, then the UPS turns itselve off. When the power comes back, the UPS turns on and the workstation boots up. If the power dies during the bootup, the UPS stays on until the Powerchute software tells it to start to shutdown again.

I really like them. I paid abuout $1500 for the APC SmartUPS 900XL with one battery and the Powerchute software for UNIX (This is where some of the confusion is, they make Powerchute for Windows, Novell, OS2, WinNT, and 10 different UNIXs). Before the UPS, I had 3 different drives fail in 6 months, 2 had to be replaced, 1 was reformatted. Since the UPS, no failures at all in 18 months.

Coincidents: maybe, but I have these UPS'es on 3 machines now.

I use an SS2 using 4.1.3 & 4.1.3_u1.

Good Luck.

Dave. ---

--------------------------------------------------------------------------

From: jjones40@pms709.pms.ford.com () Message-Id: <9408011706.AA04505@pms709.pms.ford.com> To: davido@phoenix (David Lawrence Oppenheimer) Subject: Re: Looking for UPS with auto-shutdown for Sun Status: O X-Status:

Exide, has a UPS that has served me well. It also has Sun unix software for shutdown.

Jeff Jones

----------------------------------------------------------------------------

From: amy.hollander@amp.com (Amy Hollander) Message-Id: <9408011838.AA11679@banshee.amp.com> To: davido@phoenix Subject: Re: Q: Want UPS with Solaris 1.x agent Status: O X-Status:

Leibert UPS will do this easily. Uses a software package that comes with it called PowerMon. Will shut down up to 8 unix boxes on it after a set timeout of power.

Systems Enhancement Co 11605 Lilburn Park Rd St Louis MO 63146 314-997-7717

Amy.Hollander@amp.com Amp INC Optical Connectors & Assemblies Harrisburg PA

-----------------------------------------------------------------------------

From: fmufti@genetics.bio-rad.com (Fazeel Mufti 6895) Message-Id: <9408012006.AA00805@jupiter.genetics.bio-rad.com> To: davido@phoenix Subject: Re: Q: Want UPS with Solaris 1.x agent Status: O X-Status:

I use an APC SmartUPS 900 with Powerchute Plus software. The software controls the UPS through a serial port (SNMP if you want it) and is configurable to either shutdown your computer or run your own script. It has worked very well over the past year and a half. Other people in my company have had bad experiences with other UPS vendors (can't specify as I can't find the person). Last time I checked, SunExpress had a very competitive price on these ( i got mine form them). Make sure that you get the right UPS for the load on your machine. You want to protect all peripherals on the machines in question.

APC: (800) 800-4APC SunExpress: (800) 873-7869

I got a great promotional guide from APC titled "The Power Protection Handbook". Good informational reading on UPS in general, even though it sales material. Good luck.

----------------------------------------------------------------- Fazeel Mufti fmufti@genetics.bio-rad.com phone: (510) 741-6895 fax:(510) 741-1051 Bio-Rad Laboratories, 2000 Alfred Nobel Drive, Hercules, CA 94547

-----------------------------------------------------------------------------

From: james mularadelis <jamesm@matrix.newpaltz.edu> Message-Id: <199408012142.RAA02995@matrix.newpaltz.edu> Subject: Re: Q: Want UPS with Solaris 1.x agent To: davido@phoenix Date: Mon, 1 Aug 1994 17:42:57 -0400 (EDT) In-Reply-To: <Pine.3.89.9407310821.A6399-0100000@flagstaff.Princeton.EDU> from "David Lawrence Oppenheimer" at Jul 31, 94 08:23:28 am

The best UPS is American Power Conversion

[description of what I needed deleted --ed.]

The best UPS and shutdown package that matches it is set out by APC or American Power Conversion. You can find their adds in your local 15 pound issue of Computer Shopper. We use all APC UPSs on our networks, about 6 in all.Ranging from the small 500 watt one, to the largest 2K on our nfs server. The 2K is the Smart UPS. It can keep a Sun with full mass storage unit running for up to about 10 minutes. You can configure it to reboot anytime of the week, shut down and start up on its own, and it's all done by scripts which you can edit or use the powerchute program (the package POWERCHUTE is the control app for the UPS) to watch the status of your line current, voltage, UPS temp, just about everything. It can even sample the condition of the electrical line like voltage and all user specified time intervals.

You should contact the company for more info...

I know this may sound like I work for that company, but I'm just so impressed with it's performance. This program will even let you shut down your system, power down that is by remote. Nice if you aren't in the office or lab to physicaly flip that switch...

Jim

-- James Mularadelis Academic Computing SUNY New Paltz (914) 257-3803 mulara88@matrix.newpaltz.edu

----------------------------------------------------------------------------

From: mitchell@aol14.wff.nasa.gov (Richard Mitchell 1026) Message-Id: <9408012208.AA20375@aol14> To: davido@phoenix (David Lawrence Oppenheimer) Subject: Re: Looking for UPS with auto-shutdown for Sun

We're using an American Power Conversion (APC) 1250 SmartUPS with a Sun running Solaris 2.3 (although the stack of disks that came with it also include SunOS 4.1.x and a host of others). The two are connected via a "special" (also supplied) DB9 cable.

We've only had the software for about a week and haven't actually tested the auto shutdown feature (but its supposed to be there :-) We do have it logging data and if we pull the plug, it claims it'll shut the system down in 15 minutes (a user setable option...we figure we'll be good to go for 20-30 minutes).

The intall program assumes that you'll have a floppy on the system that'll be running the software...a very poor assumption IMHO. And it looks as if their "legal" programmers got a hold of the shell scripts after the real programmers finished with them... every script begins with several lines of licensing comments, followed by the "#!/bin/sh" line...hmmmf, that should be first. I suppose I should have complained to APC, but they didn't provide an email address.

Cheers, Richard ----------------------------+----------------------------------- Richard Mitchell | Learning to Do Doing to Learn mitchell@aol14.wff.nasa.gov | Earning to Live Living to Serve N3LNK |

--------------------------------------------------------------------------

From: curt@TO.Mobil.COM (Curt Welch - RDR) Subject: Re: Looking for UPS with auto-shutdown for Sun To: davido@phoenix (David Lawrence Oppenheimer) Cc: curt@TO.Mobil.COM

We are using Back-UPS 900 from APC (American Power Conversion). They sell software called PowerChute Plus that works with our SS10s runing Solaris. I think they also support 4.1.3 but I haven't tested it. (you buy their Unix software and it comes with 5 or so disks - one for each version of Unix they support. This way they only have to sell one version of the Unix software instead of 5. There's one disk for Solaris, and another for SunOS.)

The software comes with the correct serial cable and adaptor to make it work.

We have had some minor problems, but in general, it works fine. The 900 runs our SS10s with 20" color monitors for about 30 minutes.

The minor problem is that the software should be able to detect a battery low indication and doesn't. For us, it only detects power fail (which is the important one). When the power fails, it starts sending broadcast messages every few minutes, and then does a shutdown 15 minutes later. You can set this time limit to any value you want by editing a text file.

If the power comes back on, the software sees it and stops the timer and sends a wall telling you that the power is back.

The problem is if you get a lot of short power failures, then the battery could run down and not be able to last the full 15 minutes - and since the software cannot detect the low battery signal, then the system may loose power without the shutdown running.

But we have been using this for over a year and have had many short outages and had no problems.

The other issue is that once the system is shut down, it can't tell the UPS to power off. So if the power is resstored after system shutdown, but before the UPS battery is drained, then the Sun is not rebooted automatcally. Not a big problem.

APC has a more expensive "smart" UPS that solves this. The UPS is smart enough to respond to a command to shut down in N seconds. This way, at the end of the shutdown process, the Sun can tell the UPS to give me a few more seconds and then shutdown. The smart UPS I think also retuns info like line voltage and current back to the software so it can make nice bar graphs for you.

Their phone number is 401 789-5735, or 800 800-4APC. You can find their adds in all the PC mags but they probably don't mention the fact that they have Unix software.

Curt Welch curt@kcwc.com curt@to.mobil.com

---------------------------------------------------------------------------

From: ron@mlfarm.com (Ronald Florence) Newsgroups: comp.sys.sun.hardware Subject: Re: UPS for Sparc? Message-ID: <1993Jun9.214426.373@mlfarm.com> Date: 9 Jun 93 21:44:26 GMT References: <19930608112043.sbgardne@noisycat.fms.indiana.edu> Sender: news@auda.mlfarm.com Organization: Maple Lawn Farm, Stonington, CT Lines: 162 In-Reply-To: sbgardne@bronze.ucs.indiana.edu's message of Tue, 8 Jun 1993 16:20:00 GMT

steve gardner writes:

We currently have an unused American Power Conversion (APC) 520, and have been informed by APC that we can purchase a software product called PowerChute Plus that will enable us to use the 520 with our Sparc via a com port. Before we dive in and buy the software, I'd like to solicit opinions about this and other options for UPS.

I've never used PowerChute Plus because I was too cheap to buy it. The attached code does the same thing for free. Make sure modem-control is asserted on the DEVICE serial port, and wire the cable to monitor DCD. On our Back-UPS-600, pin 2 of the 9-pin connector goes to pin 8 of a db25 serial port, and pin 4 goes to the signal ground (pin 7 of the db25). Then just start pf from /etc/rc.local.

/* * pf.c - powerfail daemon * ron@mlfarm.com, 7 Mar 1992 * original from rac@sherpa.UUCP (Roger Cornelius), 13 May 1990 * added syslog, simplified, incorporated default shutdown command */

#include <stdio.h> #include <fcntl.h> #include <signal.h> #include <setjmp.h> #include <syslog.h>

#define USAGE "Usage: pf [-d device] [-i ignoretime] [-s script]\n" #define DEVICE "/dev/ttyb" #define OPEN_TM 3 #define IGNORE 1000

jmp_buf jbuf; char *script[] = { "/usr/etc/shutdown", "-h", "now", "Power Failure", 0 };

main(argc,argv) int argc; char **argv; { void sighand(), myfork(); int didopen(), opt, ignore; char *device; extern char *optarg;

device = DEVICE; ignore = IGNORE;

if (0 != getuid()) { fputs("pf: must be root\n", stderr); exit(1); } while ((opt = getopt(argc, argv, "d:i:s:?")) != -1) { switch (opt) { case 'd': device = optarg; break; case 'i': ignore = atoi(optarg); break; case 's': *script = optarg; script[1] = '\0'; break; default : fputs(USAGE, stderr); exit(1); } } if (1 != getppid()) /* if parent not init */ { myfork(); setpgrp(); myfork(); } close(0); /* close files and make sure we don't */ close(1); /* hold any mounted fs open */ close(2); chdir("/"); /* set up syslogging, direct to */ /* console in case logger fails, */ /* no wait for child process */ openlog("UPS", LOG_CONS|LOG_NOWAIT, LOG_DAEMON);

/* * Here we attempt to open the port attached to the UPS. The open * will block (waiting for CD) until we have a power failure. When * the open succeeds (ie power fail), we close the port, sleep the * amount of time specified in `ignore', then try the open again - this * time setting an alarm. If the alarm runs out before the second * open succeeds, then we only had a temporary outage and this whole * process starts over, (ie the alarm is caught by sighand() which * longjmp()'s back to here). If instead the second open succeeds, * then we assume it's an extended failure so we exec /etc/shutdown, * after a warning and one final try to open the line. */ restart: setjmp(jbuf); /* jump back here on false alarm */ if (didopen(device)) /* power failure */ { syslog(LOG_CRIT, "Power Line Event"); sleep(ignore); signal(SIGALRM, sighand); alarm(OPEN_TM); if (didopen(device)) { syslog(LOG_ALERT, "Power Line Failure - System Going Down in 60 seconds"); alarm(0); sleep(60); if (didopen(device)) { execvp(script[0], script); syslog(LOG_ALERT, "Unable to shutdown system"); } else { syslog(LOG_CRIT, "Power Restored"); goto restart; } } } exit(0); }

void myfork() { int stat;

stat = fork(); if (stat < 0) syslog(LOG_ALERT,"pf: fork failed"); else if (stat > 0) /* parent */ exit(0); }

/* * Attempt to open the device attached to the UPS * Should never succeed except during power failure */ int didopen(device) char *device; { int fd;

fd = open(device, O_RDONLY); if (fd != -1) { close(fd); return(1); } syslog(LOG_ALERT, "pf: bogus open on UPS line"); exit(1); }

void sighand(sig) int sig; { longjmp(jbuf,1); }

--

Ronald Florence ron@mlfarm.com

-- Mark G. Thomas (Mark@Misty.com)

----------------------------------------------------------------------------

From: dave@lpdwhy.bhp.com.au (David Robson) Message-Id: <9408020646.AA18956@lpdwhy.bhp.com.au> Subject: Re: Q: Want UPS with Solaris 1.x agent To: davido@phoenix Date: Tue, 2 Aug 94 16:46:19 EST

There are a number of UPS supliers to choose from. Two that come to mind are SOLAR (American I believe), and Epsilon. Epsilon is in use here on DEC Alpha and will likly be in use on several SPARC 5s in the near future. I've tested their software under Solaris 2.3 - works fine. They have a number of configuration options and the software is optional. Communication is via RS232 serial port.

EPSILON Pty Ltd, PO BOX 686, Seven Hills SYDNEY, Australia 2147 FAX:+61 2 674 3897 PHONE:+61 2 838 9966

There are a couple of other suppliers, but I don't have details to hand - if your really stuck I'll find out.

-- David Robson (ROBBO),BHP Information Technology, P.O.Box 21, Whyalla South Australia 5600, Ph: +61 86 404596 Fax:...404720, E-mail dave@lpdwhy.bhp.com.au "Life's battle's don't always go To the stronger or faster man, But soon or late, the man who wins, IS THE MAN WHO THINKS HE CAN." -- Walter W. Wintle

-----------------------------------------------------------------------------

From: ron@mlfarm.com (Ronald Florence) Message-Id: <199408020946.FAA22532@auda.mlfarm.com> To: davido@phoenix (David Lawrence Oppenheimer) In-Reply-To: davido@Princeton.EDU's message of Sun, 31 Jul 1994 12:27:48 GMT Subject: Looking for UPS with auto-shutdown for Sun Status: O X-Status:

David Lawrence Oppenheimer writes:

If anyone is using a UPS with auomatic shutdown capabilities for SunOS 4.1.3, or has written a script to take the "shutdown" signal from the UPS and turn in into a, say "shutdown +5" command, please let me know.

/* * pf.c - powerfail daemon * ron@mlfarm.com, 7 Mar 1992 * original from rac@sherpa.UUCP (Roger Cornelius), 13 May 1990 * * To install, you need a serial port with modem-control enabled. For * Sunos-4.1.* put "off remote" in the `status' column of /etc/ttytab * for the serial port that will be connected to the UPS. * * The cable from the UPS needs only two wires, the signal ground from * the UPS should be connected to the signal ground on the serial port * [pin 7 on a 25-pin port, pin, pin 5 on a 9-pin port, or pin 4 on * the Sun IPC/IPX serial ports]; the powerfail signal from the UPS to * CD [pin 8 on a 25-pin port, pin 1 on a 9-pin port, or pin-7 on the * Sun IPC/IPX serial ports]. * * Define DEVICE, the serial port that will monitor the UPS, and * IGNORE, the time in seconds before a system shutdown is initiated, * to suit your setup. You can also specify the device, ignoretime, * or the shutdown script on the command line when pf is started. The * normal usage is to put pf somewhere in /etc/rc.local. * * compile: [g]cc -O -o pf pf.c */

#include <stdio.h> #include <fcntl.h> #include <signal.h> #include <setjmp.h> #include <syslog.h>

#define USAGE "Usage: pf [-d device] [-i ignoretime] [-s script]\n" #define DEVICE "/dev/ttyb" #define OPEN_TM 3 #define IGNORE 1000

jmp_buf jbuf; char *script[] = { "/usr/etc/shutdown", "-h", "now", "Power Failure", 0 };

main(argc,argv) int argc; char **argv; { void sighand(), myfork(); int didopen(), opt, ignore; char *device; extern char *optarg;

device = DEVICE; ignore = IGNORE;

if (0 != getuid()) { fputs("pf: must be root\n", stderr); exit(1); } while ((opt = getopt(argc, argv, "d:i:s:?")) != -1) { switch (opt) { case 'd': device = optarg; break; case 'i': ignore = atoi(optarg); break; case 's': *script = optarg; script[1] = '\0'; break; default : fputs(USAGE, stderr); exit(1); } } if (1 != getppid()) /* if parent not init */ { myfork(); setpgrp(); myfork(); } close(0); /* close files and make sure we don't */ close(1); /* hold any mounted fs open */ close(2); chdir("/"); /* set up syslogging, direct to */ /* console in case logger fails, */ /* no wait for child process */ openlog("UPS", LOG_CONS|LOG_NOWAIT, LOG_DAEMON);

/* * Here we attempt to open the port attached to the UPS. The open * will block, waiting for CD, until we have a power failure. When * the open succeeds, we close the port, sleep the amount of time * specified in `ignore', then try the open again, this time setting * an alarm. If the alarm runs out before the second open succeeds, * we only had a temporary outage and the process starts over. If the * second open succeeds, we assume it's an extended failure so we exec * /etc/shutdown, after a warning and one final try to open the line. */

restart: setjmp(jbuf); if (didopen(device)) /* power failure */ { syslog(LOG_CRIT, "Power Line Event"); sleep(ignore); signal(SIGALRM, sighand); alarm(OPEN_TM); if (didopen(device)) { syslog(LOG_ALERT, "Power Line Failure - System Going Down in 60 seconds"); alarm(0); sleep(60); if (didopen(device)) { execvp(script[0], script); syslog(LOG_ALERT, "Unable to shutdown system"); } else { syslog(LOG_CRIT, "Power Restored"); goto restart; } } } exit(0); }

void myfork() { int stat;

stat = fork(); if (stat < 0) syslog(LOG_ALERT,"pf: fork failed"); else if (stat > 0) /* parent */ exit(0); }

/* * Attempt to open the device attached to the UPS * Should never succeed except during power failure */ int didopen(device) char *device; { int fd;

fd = open(device, O_RDONLY); if (fd != -1) { close(fd); return(1); } syslog(LOG_ALERT, "pf: bogus open on UPS line"); exit(1); }

void sighand(sig) int sig; { longjmp(jbuf,1); }

-----------------------------------------------------------------------------

Date: Tue, 2 Aug 94 10:12:08 CDT From: watsont@uranium.brooks.af.mil (Tim Watson) Message-Id: <9408021512.AA08622@uranium.brooks.af.mil> To: davido@Princeton.EDU Subject: Re: Looking for UPS with auto-shutdown for Sun

David,

We are using a UPS called SmartUPS 1200 (also SmartUPS 900) from American Power Conversion (APC). Their UPS has a serial connection which goes to the Sun box. They also supplied software called PowerChute. The software will notice when power to the UPS is lost and after a user defined period, send a wall command to all users that the system will shutdown in x minutes (x is also user defined). If power is restored before the shutdown, the system sends a wall that power has been restored. The system will continue to run based on the amount of time you told it the UPS would last (basically the x minutes above) and then perform a shutdown. If you over estimated the time to battery loss, the system will send out a quick wall message that the UPS is about to die and then it shutsdown. Once the power is restored, the UPS supplies power to the system again to reboot.

One nice thing about the software is that the wall messages are sent from scripts (a seperate one for each condition: power out, battery low, and power restored). They commented that one could put a line in each of these scripts to send mail to root (or whoever). I went one step further and sent mail to an account which forwards mail to my account PLUS sends a copy to a ccmail (PC) account which is forwarded to the fax modem. So now, at 4am when the power goes out, I get a fax at home so when I wake up, I know I have to drive REALLY fast to get to the office to figure out why I didn't get a fax about power restored. :-)

We've been very happy with it so far.

Let me know if you need any additional info.

+-------------------------------------------------------------------------+ | Timothy D. Watson (watsont@radon.brooks.af.mil) Work: 210-536-4199 | | Brooks Air Force Base, San Antonio, Texas Home: 210-554-9541 | | "Life is a matter of choices, not chances." Fax: 210-341-3212 | +-------------------------------------------------------------------------+ George Orwell was only off by ten years.

---------------------------------------------------------------------------

From: "ROBERT LOWY" <LOWY@vax.afrri.usuhs.mil> Subject: RE: Looking for UPS with auto-shutdown for Sun To: "davido" <davido@Princeton.EDU>

Take a look at Best. I believe they have a UNIX interface/script for shutdown. I have an ancient (System V dot nothing ) runnging off a 2.2 kva system for 4 years (continously) No problems - even the day my lab flooded with 6 inches of water. My recollection is I bought a unix script for shuut down but I've never installed it. (I'm at home and can't check the disk dos/unix?) Their systems do talk to even dumb terminal via rs232 for all sorts of diagnostics fault records etc. so expect what you want is possible.

----------------------------------------------------------------------- Joel Lowy The usual disclaimers. lowy@vax.afrri.usuhs.mil -----------------------------------------------------------------------

----------------------------------------------------------------------------

From: npc@minotaur.jpl.nasa.gov Message-Id: <199408032004.NAA03533@minotaur.jpl.nasa.gov> To: davido@phoenix Subject: Re: Q: Want UPS with Solaris 1.x agent Newsgroups: info.sun-managers In-Reply-To: <Pine.3.89.9407310821.A6399-0100000@flagstaff.princeton.edu> Organization: Jet Propulsion Laboratory, Pasadena, CA

In article <Pine.3.89.9407310821.A6399-0100000@flagstaff.princeton.edu> you write: >Sun-Managers: > >I'm looking for a UPS unit which can be connected to a Sun (I'm using an >SS5 and SunOS 4.1.3_U1) and which will do automatic shutdown upon >detecting a power loss.

Several UPS manufacturers provide this. We use APC Smart-UPS units with APC's Powerchute software and it has worked nicely.

>I would rather not have to mess around with SNMP, unless I can find >software which will take care of both ends of the SNMP conversation (the >UPS and the Sun) without requiring me to hack around in SNMP.

Understandable, and I believe that such SW exists, but I have no experience with it.

>If anyone is using a UPS with auomatic shutdown capabilities for SunOS >4.1.3, or has written a script to take the "shutdown" signal from the UPS >and turn in into a, say "shutdown +5" command, please let me know.

There is a freely distributable source version of upsd. I don't know where the original or an up-to-date copy might be found, but a copy is available via anonymous ftp as: ftp://navigator.jpl.nasa.gov/pub/src/upsd.tar.Z

>I will of course post a summary of my findings to this list. Thanks!

If I might be allowed a not-so-small plug, these questions are dealt with in the UPS FAQ, available via anonymous FTP as: ftp://navigator.jpl.nasa.gov/pub/doc/faq/UPS.faq

Hope this has been helpful.

-- Nick Christenson npc@minotaur.jpl.nasa.gov

---------------------------------------------------------------------------

From: Richard Skelton <rich@brake.demon.co.uk> Message-Id: <9408032120.AA00336@ brake.demon.co.uk> To: davido@phoenix Subject: Re: Q: Want UPS with Solaris 1.x agent

Hi David, In the UK SunExpress have a power management system called "Smart-UPS". The UPS can be combined with some software called "PowerChute PLUS for UNIX". The UPS systems are a series made by a company called "American Power Conversion(APC)" The UPS will connect to one of the serial lines on your Sparc 5. In the UK the 250W UPS is #230 and the software PowerChute is #100.

Hope this is usefull, Richard Skelton | e-mail : Richard.Skelton@brake.demon.co.uk

-----------------------------------------------------------------------------

In addition to the above, thanks to the following individuals who also suggested one or more of the products mentioned above:

From: Mike Raffety <mike_raffety@il.us.swissbank.com> From: dcc@raleigh.ssds.com (Derrick Cole - Raleigh) From: Dan Jiracek <djiracek@fnbc.com> From: Todd Pfaff <todd@water.eng.mcmaster.ca> From: friedel@wise.TAU.AC.IL (Friedel Loinger) From: "Martin" <martin@qbridge.ich.nl> From: behr@math.niu.edu (Eric Behr) From: john@oncology.uthscsa.edu (John Justin Hough) From: lcollera@amgen.com (Lori Colleran) From: Mike Rembis 66520 <ebumfr@ebu.ericsson.se> From: kenp@lust.Jpl.Nasa.Gov (Ken Peters) From: root@ss10.wkstech.com (Operator) From: steve@ramsey.cs.laurentian.ca (Stephen R. Czapor) From: edk@mach10.utica1.kaman.com (Edward F Killian) From: borisa@rockie.nsc.com (Boris Abramzon) From: ken@zeus.ST.3Com.COM (Ken Descoteaux) From: crm@lgi.com (Charles Mengel) From: crf@access.digex.net (Clarke Ferber) From: worsham@aer.com (Robert D. Worsham) From: wayner@sunbrew.Central.Sun.COM (Jim Wayner Sun Milwaukee SE)

My apologies if I left anyone out by accident.

Thanks to everyone who responded! I think this experience has provided a very comprehensive view of the UPS-with-UNIX-shutdown-capabilities products currently available.

David Oppenheimer davido@Princeton.EDU



This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:09:07 CDT