table of contents
UPS.CONF(5) | NUT Manual | UPS.CONF(5) |
NAME¶
ups.conf - UPS definitions for Network UPS ToolsDESCRIPTION¶
This file is read by the driver controller upsdrvctl(8), the UPS drivers that use the common core (see nutupsdrv(8), and upsd(8)). The file begins with global directives, and then each UPS has a section which contains a number of directives that set parameters for that UPS.[myups] driver = blazer_ser port = /dev/ttyS0 desc = "Web server UPS"
[bigups] driver = apcsmart port = /dev/cua00 cable = 940-0095B sdtype = 2 desc = "Database server UPS"
GLOBAL DIRECTIVES¶
chrootOptional. The driver will chroot(2) to this
directory during initialization. This can be useful when securing
systems.
driverpath
Optional. Path name of the directory in which
the UPS driver executables reside. If you don’t specify this, the
programs look in a built-in default directory, which is often
/usr/local/ups/bin.
maxstartdelay
Optional. Same as the UPS field of the same
name, but this is the default for UPSes that don’t have the field.
pollinterval
Optional. The status of the UPS will be
refreshed after a maximum delay which is controlled by this setting. This is
normally 2 seconds. This may be useful if the driver is creating too much of a
load on your system or network.
user
Optional. If started as root, the driver will
setuid(2) to the user id associated with username.
UPS FIELDS¶
driverRequired. This specifies which program will be
monitoring this UPS. You need to specify the one that is compatible with your
hardware. See nutupsdrv(8) for more information on drivers in general
and pointers to the man pages of specific drivers.
port
Required. This is the serial port where the
UPS is connected. On a Linux system, the first serial port usually is
/dev/ttyS0. On FreeBSD and similar systems, it probably will be
/dev/cuaa0.
sdorder
Optional. When you have multiple UPSes on your
system, you usually need to turn them off in a certain order. upsdrvctl shuts
down all the 0s, then the 1s, 2s, and so on. To exclude a UPS from the
shutdown sequence, set this to -1.
The default value for this parameter is 0.
desc
Optional. This allows you to set a brief
description that upsd will provide to clients that ask for a list of connected
equipment.
nolock
Optional. When you specify this, the driver
skips the port locking routines every time it starts. This may allow other
processes to seize the port if you start more than one accidentally.
You should only use this if your system won’t work without it.
This may be needed on Mac OS X systems.
ignorelb
Optional. When you specify this, the driver
ignores a low battery condition flag that is reported by the UPS (some devices
will switch off almost immediately after setting this flag, or will report
this as soons as the mains fails). Instead it will use either of the following
conditions to determine when the battery is low:
The idea is to set the battery.charge.low and/or battery.runtime.low levels in
ups.conf to a value that gives enough time to cleanly shutdown your
system:
In order for this to work, your UPS should be able to (reliably) report charge
and/or runtime remaining on battery. Use with caution!
maxstartdelay
battery.charge < battery.charge.low battery.runtime < battery.runtime.low
override.battery.charge.low = 30 override.battery.runtime.low = 180
Optional. This can be set as a global variable
above your first UPS definition and it can also be set in a UPS section. This
value controls how long upsdrvctl will wait for the driver to finish starting.
This keeps your system from getting stuck due to a broken driver or UPS.
The default is 45 seconds.
default.<variable>
Optional. Set a default value for
<variable> which is used in case the UPS doesn’t provide a value,
but will be overwritten if a value is available from the UPS:
The above will report the nominal input voltage to be 230, unless the UPS tells
us differently.
override.<variable>
default.input.voltage.nominal = 230
Optional. Set a value for <value> that
overrides any value that may be read from the UPS. Used for overriding values
from the UPS that are clearly wrong (some devices report wrong values for
battery voltage for instance):
Use with caution! This will only change the appearance of the variable to the
outside world, internally in the UPS the original value is used.
override.battery.voltage.nominal = 12
INTEGRATION¶
upsdrvctl(8) uses this file to start and stop the drivers.SEE ALSO¶
upsd(8), nutupsdrv(8), upsdrvctl(8)Internet resources¶
The NUT (Network UPS Tools) home page: http://www.networkupstools.org/05/21/2012 | Network UPS Tools |