[Nut-upsuser] getting nut 2.6.4 working in Nas4Free

James Abernathy jfabernathy at gmail.com
Tue Jul 24 09:57:50 UTC 2012


On Tue, Jul 24, 2012 at 3:18 AM, <FredericBohe at eaton.com> wrote:

>  Hello Jim,
>
> Can you send your configuration files please (hide your password).
>
> Regards,
> Fred
>
> --
> Eaton Opensource Team - http://opensource.eaton.com
>
>
>
I hope I'm sending the right stuff. It's out of the box setup. I didn't
edit anything except the port and driver, and email stuff.
/var/etc/ups.conf is

 [ups]
        driver = usbhid-ups
        port = auto

/var/etc/nut.conf is

MODE = standalone

/var/etc/upsd.conf is

MAXAGE 15
MAXCONN 1024
LISTEN 127.0.0.1 3493
LISTEN ::1 3493

/var/etc/upds.users is

[root]
        password = xxxxxxx
        actions = set
        instcmds = all
        upsmon master

/var/etc/upsmon.conf is

MONITOR ups at localhost 1 root password master
MINSUPPLIES 1
SHUTDOWNCMD "/sbin/shutdown -p now"
NOTIFYCMD /usr/local/sbin/upssched
POLLFREQ 5
POLLFREQALERT 5
HOSTSYNC 15
DEADTIME 15
POWERDOWNFLAG /var/etc/killpower
NOTIFYFLAG ONLINE SYSLOG+WALL+EXEC
NOTIFYFLAG ONBATT SYSLOG+WALL+EXEC
NOTIFYFLAG LOWBATT SYSLOG+WALL+EXEC
NOTIFYFLAG FSD SYSLOG+WALL+EXEC
NOTIFYFLAG COMMOK SYSLOG+WALL+EXEC
NOTIFYFLAG COMMBAD SYSLOG+WALL+EXEC
NOTIFYFLAG SHUTDOWN SYSLOG+WALL+EXEC
NOTIFYFLAG REPLBATT SYSLOG+WALL+EXEC
NOTIFYFLAG NOCOMM SYSLOG+WALL+EXEC
NOTIFYFLAG NOPARENT SYSLOG+WALL+EXEC
RBWARNTIME 43200
NOCOMMWARNTIME 300
FINALDELAY 5

/var/etc/upssched.conf is

CMDSCRIPT /usr/local/bin/upssched-cmd
PIPEFN /var/run/upssched.pipe
LOCKFN /var/run/upssched.lock

AT COMMOK * EXECUTE notify
AT COMMBAD * EXECUTE notify
AT REPLBATT * EXECUTE notify
AT NOCOMM * EXECUTE notify
AT FSD * EXECUTE forced-shutdown
AT NOPARENT * EXECUTE notify
AT SHUTDOWN * EXECUTE notify
AT ONLINE * CANCEL-TIMER shutdown
AT ONLINE * EXECUTE resume
AT ONBATT * START-TIMER shutdown 30
AT ONBATT * EXECUTE shutdown-warning
AT LOWBATT * START-TIMER shutdown
AT LOWBATT * EXECUTE shutdown-warning

Jim A

>  ------------------------------
>
> ------------------------------
>
>
>
> ------------------------------
> *From:* nut-upsuser-bounces+fredericbohe=eaton.com at lists.alioth.debian.org[nut-upsuser-bounces+fredericbohe=
> eaton.com at lists.alioth.debian.org] on behalf of Jim Abernathy [
> jfabernathy at gmail.com]
> *Sent:* Monday, July 23, 2012 9:51 PM
> *To:* nut-upsuser at lists.alioth.debian.org
> *Subject:* [Nut-upsuser] getting nut 2.6.4 working in Nas4Free
>
>  I'm trying to use a Nas4Free storage system.  This same hardware worked
> fine on Freenas 0.7.2.
>
> O/S: Nas4Free 9.0.0.1.148 which comes with nut 2.6.4.
>
> UPS is an APC Back UPS RS 800.  USB interface.
>
> Driver : usbhid-ups
> Port: auto
>
> my NAS is communicating with the UPS, but in testing power failures, I'm
> not getting the shutdown to be handled properly.
>
> When I pull the AC plug on the UPS, the NAS recognizes that event, but
> doesn't send out the email and doesn't start the shutdown sequence even
> though the 30 sec time limit has passed. The log shows errors. I've posted
> them below. The restoring of power is also recognized by the NAS.
>
> Jul 14 06:14:41 nas4free upsmon[1813]: UPS Back-UPS-RS-800 at localhost on
> battery
>
> Jul 14 06:14:42 nas4free upssched[2334]: read confirmation got [ERR
> UNKNOWN own" "30"]
> Jul 14 06:14:43 nas4free last message repeated 24 times
> Jul 14 06:14:43 nas4free upssched[2334]: Unable to connect to daemon and
> unable to start daemon
>
> Jul 14 06:17:01 nas4free upsmon[1813]: UPS Back-UPS-RS-800 at localhost on
> line power
> Jul 14 06:17:01 nas4free upssched-cmd: UPS Back-UPS-RS-800 at localhost -
> Running on line power. Shutdown cancelled.
>
> Jul 14 06:17:03 nas4free msmtp: host=smtp.gmail.com tls=on auth=on
> user=xyz at gmail.com from=xyz at gmail.com recipients=xyz at gmail.commailsize=244 smtpstatus=250 smtpmsg='250 2.0.0 OK 1342261023
> y66sm18956640yhi.10' exitcode=EX_OK
>
> more information in the daemon log file:
>
> Jul 14 08:35:17 nas4free upsmon[6990]: UPS ups at localhost on battery
> Jul 14 08:35:17 nas4free upssched[7010]: Timer daemon started
> Jul 14 08:35:17 nas4free upssched[7010]: Unknown command on socket:
> Jul 14 08:35:17 nas4free upssched[7010]: arg 0: 30START
> Jul 14 08:35:17 nas4free upssched[7010]: arg 1: shutdown
> Jul 14 08:35:17 nas4free upssched[7010]: arg 2: 30
> Jul 14 08:35:17 nas4free upssched[7009]: read confirmation got [ERR
> UNKNOWN own" "30"]
>
> Jim A
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/nut-upsuser/attachments/20120724/854d31f1/attachment.html>


More information about the Nut-upsuser mailing list