This is the first time that i had to use E-mail like forums i'm only hitting 
reply to mail NOT replay to all mails

THIS IS upssched.conf

# This file is auto-generated by openmediavault (https://www.openmediavault.org)
# WARNING: Do not edit this file, your changes will get lost.
CMDSCRIPT /usr/bin/upssched-cmd
PIPEFN /run/nut/upssched.pipe
LOCKFN /run/nut/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 15
AT ONBATT * EXECUTE shutdown-warning
AT LOWBATT * START-TIMER shutdown
AT LOWBATT * EXECUTE shutdown-warning




BTW i finished the last TEST with everything hooked to my UPS and it seems that 
this line POWERDOWNFLAG /etc/killpower
was what causing my UPS to shut itself down after a period of time

i really don't know if deleting POWERDOWNFLAG was the right choice or not but 
if there is anything i can do to properly fix it please let me know



________________________________
From: Nut-upsuser 
<nut-upsuser-bounces+princemodey=hotmail....@alioth-lists.debian.net> on behalf 
of nut-upsuser-requ...@alioth-lists.debian.net 
<nut-upsuser-requ...@alioth-lists.debian.net>
Sent: Sunday, September 8, 2024 2:00 PM
To: nut-upsuser@alioth-lists.debian.net <nut-upsuser@alioth-lists.debian.net>
Subject: Nut-upsuser Digest, Vol 231, Issue 4

Send Nut-upsuser mailing list submissions to
        nut-upsuser@alioth-lists.debian.net

To subscribe or unsubscribe via the World Wide Web, visit
        https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser
or, via email, send a message with subject or body 'help' to
        nut-upsuser-requ...@alioth-lists.debian.net

You can reach the person managing the list at
        nut-upsuser-ow...@alioth-lists.debian.net

When replying, please edit your Subject line so it is more specific
than "Re: Contents of Nut-upsuser digest..."


Today's Topics:

   1. Re: Nut-upsuser Digest, Vol 231, Issue 2 (Roger Price)
   2. Re: Nut-upsuser Digest, Vol 231, Issue 2 (Jim Klimov)


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

Message: 1
Date: Sat, 7 Sep 2024 17:16:40 +0200 (CEST)
From: Roger Price <ro...@rogerprice.org>
To: Mega DooOooM via Nut-upsuser <nut-upsuser@alioth-lists.debian.net>
Subject: Re: [Nut-upsuser] Nut-upsuser Digest, Vol 231, Issue 2
Message-ID: <fa5f98c0-4330-35c0-6c17-571ba631c...@rogerprice.org>
Content-Type: text/plain; charset=US-ASCII; format=flowed

On Sat, 7 Sep 2024, Mega DooOooM via Nut-upsuser wrote:

> and this is UPSMON.CONF lines
>
> # This file is auto-generated by openmediavault 
> (https://www.openmediavault.org)
> # WARNING: Do not edit this file, your changes will get lost.
> MONITOR back-ups 1 monmaster 4L[p9<0Vi|Z>xKgK master
> MINSUPPLIES 1
> SHUTDOWNCMD "/sbin/shutdown -h +0"
> NOTIFYCMD "/sbin/upssched"
> POLLFREQ 5
> POLLFREQALERT 5
> HOSTSYNC 15
> DEADTIME 555
> POWERDOWNFLAG /etc/killpower
> NOTIFYFLAG ONLINE SYSLOG+WALL+EXEC
> NOTIFYFLAG ONBATT SYSLOG+WALL+EXEC
> NOTIFYFLAG LOWBATT 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 FSD SYSLOG+WALL+EXEC
> RBWARNTIME 43200
> NOCOMMWARNTIME 300
> FINALDELAY 5

The EXEC flag with the NOTIFYFLAG says that when a NOTIFY event occurs, upsmon
calls the program identified by NOTIFYCMD "/sbin/upssched".  Does this program
have a configuration file?  Perhaps upssched.conf.  Could we see it?

Roger

PS - You dont have to repeat all the previous messages in the Digest.



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

Message: 2
Date: Sat, 7 Sep 2024 23:27:36 +0200
From: Jim Klimov <jimklimov+...@gmail.com>
To: Mega DooOooM <princemo...@hotmail.com>
Cc: nut-upsuser Mailing List <nut-upsu...@lists.alioth.debian.org>
Subject: Re: [Nut-upsuser] Nut-upsuser Digest, Vol 231, Issue 2
Message-ID:
        <CAJYg8vKuKxRAj-vbjUExur8r=rccoahud5otfrg5tokrown...@mail.gmail.com>
Content-Type: text/plain; charset="utf-8"

Cheers, jumping into the discussion late from some travels, sorry.

In the original post, is the "Server PC" the OMV with NUT? Are any of your
other machines running NUT (e.g. the `upsmon` client for shutdowns)?

What I guess may be happening is:

* OMV has the physical connection needed to monitor and command the UPS,
and its `upsmon` has `MONITOR` for it as `primary` (ex-`master`);
* by definition, such a "primary" instance in case of a power outage (and
"critical state" of the UPS battery, definitions vary) is responsible for
yelling "FSD" (Forced ShutDown) to all other "secondary" clients connected
to tge same `upsd` data server (maybe none in your case), waiting for them
all (if any) to disconnect - presumably meaning they are going down, and
shuts down itself.
* With the "killpower" file in place (created as part of "primary" FSD
handling), and some OS shutdown integration, it would also tell all
connected UPSes to power off (or power-cycle if power came back, aka "power
race condition", to avoid your systems staying down indefinitely), if the
UPS and its NUT driver agree how to support such behavior.

This seems aligned with what you see in practice.

One quick fix can be to change the OMV `MONITOR` mode to `secondary`
(ex-`slave`) so only it shuts down when power goes "bad".

Nuanced criteria for the latter, like time spent on battery, can be set in
`upssched` (as asked about by Roger). Default "bad"ness is defined by UPS
itself claiming a low battery state, maybe also by remaining percentage
(depends on driver and device).

Hope this helps,
Jim Klimov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: 
<http://alioth-lists.debian.net/pipermail/nut-upsuser/attachments/20240907/07616461/attachment-0001.htm>

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

Subject: Digest Footer

_______________________________________________
Nut-upsuser mailing list
Nut-upsuser@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser


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

End of Nut-upsuser Digest, Vol 231, Issue 4
*******************************************
_______________________________________________
Nut-upsuser mailing list
Nut-upsuser@alioth-lists.debian.net
https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/nut-upsuser

Reply via email to