nut
Table des matières
Onduleurs : arrêt automatique des serveurs
Le programme nut communique avec l'onduleur et déclenche l'arrêt du serveur “proprement” en cas de panne prolongée, avant la décharge complète des batteries.
aptitude install nut
Pour les serveurs sous debian 5 (nut version 2.2)
/etc/default/nut
# start upsd START_UPSD=yes # set upsd specific options. use "man upsd" for more info UPSD_OPTIONS="" # start upsmon START_UPSMON=yes # set upsmon specific options. use "man upsmon" for more info UPSMON_OPTIONS=""
/etc/nut/nut.conf
MODE=standalone
/etc/nut/ups.conf
[apc] driver = usbhid-ups port = /dev/usb/hiddev0 # ou /dev/bus/usb/001/004 desc = "APC ES 550"
/etc/nut/upsd.conf
LISTEN localhost 3493 ACL localhost 127.0.0.1/32 ACCEPT localhost
/etc/nut/upsd.users
[admin] password = adminpass actions = SET instcmds = ALL [user] password = mypass allowfrom = localhost upsmon master
/etc/nut/upsmon.conf
MONITOR apc@localhost 1 user mypass master MINSUPPLIES 1 FINALDELAY 5 HOSTSYNC 15 SHUTDOWNCMD "/sbin/shutdown -h +0" POWERDOWNFLAG /etc/killpower POLLFREQ 5 POLLFREQALERT 5 DEADTIME 15 NOCOMMWARNTIME 300 RBWARNTIME 43200
Pour le serveur sous ubuntu 10.04 (nut version 2.4)
Il n'y a pas de fichier /etc/default/nut
/etc/nut/nut.conf
MODE=standalone
/etc/nut/upsd.conf
MAXAGE 15 LISTEN 127.0.0.1 3493 MAXCONN 1024
/etc/nut/upsd.users
[user]
password = mypass
upsmon master
/etc/nut/upsmon.conf
MONITOR apc@localhost 1 user mypass master MINSUPPLIES 1 FINALDELAY 5 HOSTSYNC 15 SHUTDOWNCMD "/sbin/shutdown -h +0" POWERDOWNFLAG /etc/killpower POLLFREQ 5 POLLFREQALERT 5 DEADTIME 15 NOCOMMWARNTIME 300 RBWARNTIME 43200
nut.txt · Dernière modification : de 127.0.0.1
