[Nut-upsuser] NUT for laptop

Arnaud Quette aquette.dev at gmail.com
Wed May 7 15:17:35 UTC 2008

2008/5/2 Emard <davoremard at gmail.com>:
> On Fri, May 02, 2008 at 09:29:28AM +0200, Arnaud Quette wrote:
>  > Hi Emard,
>  >
>  > 2008/5/2 Emard <davoremard at gmail.com>:
>  > > HI all
>  > >
>  > >  How to setup nut to use and monitor laptop battery on linux?
>  > >  (/proc/acpi/battery/BAT0/state)
>  >
>  > why would you do so? there is nothing to gain doing so (no
>  Laptop may be considered a replacement (or "hot-spare") for the
>  if a real nut server in the production setup goes down.
>  > master/slave conf possible).
>  Why not? Machines (slaves) on the network may be on dumb ups-es with
>  no management link, and be connected to network with a nut running on
>  a laptop (master) which 'knows' power fail condition and serve
>  dumb ups machines, shutting them down few minutes after power failure.
>  Much better than dumb ups alone.

ok, having this use case makes things more clear ;-)

you might consider using dummy-ups to do this task, and either:
1) create a script that is cron'ed every minute (or so) and feed
dummy-ups (using upsrw) according to the current status
2) modify dummy-ups to parse the battery status in its update loop

You might also want to put a  "powervalue" of 0 in upsmon.conf ->
MONITOR for the laptop.

Linux / Unix Expert R&D - MGE Office Protection Systems - http://www.mgeops.com
Network UPS Tools (NUT) Project Leader - http://www.networkupstools.org/
Debian Developer - http://people.debian.org/~aquette/
Free Software Developer - http://arnaud.quette.free.fr/

More information about the Nut-upsuser mailing list