[Nut-upsuser] wrong NOTIFYTYPE always ONBATT on upssched TIMER ?

RemiG mailing-nut at dbmtechnologies.com
Wed Apr 2 08:42:13 BST 2025


Hi Jim

ii  nut                                   2.7.4-13 
                           all          network UPS tools - metapackage 
ii  nut-client                            2.7.4-13 
                           amd64        network UPS tools - clients ii 
  nut-server                            2.7.4-13 
                           amd64        network UPS tools - core system 
debian 11 I'am using an older eaton with faulty battery for this test. 
goint to redo with a good battery ...

Le 02/04/2025 à 09:02, nut-upsuser-request at alioth-lists.debian.net a écrit :
> Send Nut-upsuser mailing list submissions to
> 	nut-upsuser at 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-request at alioth-lists.debian.net
>
> You can reach the person managing the list at
> 	nut-upsuser-owner at 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. wrong NOTIFYTYPE always ONBATT on upssched TIMER ? (RemiG)
>     2. Re: wrong NOTIFYTYPE always ONBATT on upssched TIMER ?
>        (Jim Klimov)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Tue, 1 Apr 2025 17:22:54 +0200
> From: RemiG<mailing-nut at dbmtechnologies.com>
> To:nut-upsuser at alioth-lists.debian.net
> Subject: [Nut-upsuser] wrong NOTIFYTYPE always ONBATT on upssched
> 	TIMER ?
> Message-ID:<c45d0396-d155-d8fb-716e-b18abe23c255 at dbmtechnologies.com>
> Content-Type: text/plain; charset="utf-8"; Format="flowed"
>
> HI
>
> i'am using schema upsmon call : NOTIFYCMD /sbin/upssched
>
> and this part of upsschede strategy (working fine)
>
> device.model: Ellipse ECO 650
>
> root at ---:~# cat /etc/nut/upssched.conf
> # Network UPS Tools - upssched.conf sample file
>
> CMDSCRIPT /opt/nut/bin/upssched-cmd
>
> PIPEFN /var/run/nut/upssched.pipe
> LOCKFN /var/run/nut/upssched.lock
>
> #
> ============================================================================
> # info2client
> AT ONLINE * EXECUTE ONLINE
> # info2admin only
> AT ONLINE * CANCEL-TIMER BATT-STATUS-5
> AT ONLINE * CANCEL-TIMER BATT-STATUS-10
> AT ONLINE * CANCEL-TIMER BATT-STATUS-15
> AT ONLINE * CANCEL-TIMER BATT-STATUS-20
> AT ONLINE * CANCEL-TIMER BATT-STATUS-25
> AT ONLINE * CANCEL-TIMER BATT-STATUS-30
> AT ONLINE * CANCEL-TIMER BATT-STATUS-60
> AT ONLINE * START-TIMER LINE-STATUS-5 300
> AT ONLINE * START-TIMER LINE-STATUS-10 600
> AT ONLINE * START-TIMER LINE-STATUS-15 900
> AT ONLINE * START-TIMER LINE-STATUS-20 1200
> AT ONLINE * START-TIMER LINE-STATUS-25 1500
> AT ONLINE * START-TIMER LINE-STATUS-30 1800
> AT ONLINE * START-TIMER LINE-STATUS-60 3600
> #
> # info2client
> AT ONBATT * EXECUTE ONBATT
> # info2admin only
> AT ONBATT * CANCEL-TIMER LINE-STATUS-5
> AT ONBATT * CANCEL-TIMER LINE-STATUS-10
> AT ONBATT * CANCEL-TIMER LINE-STATUS-15
> AT ONBATT * CANCEL-TIMER LINE-STATUS-20
> AT ONBATT * CANCEL-TIMER LINE-STATUS-25
> AT ONBATT * CANCEL-TIMER LINE-STATUS-30
> AT ONBATT * CANCEL-TIMER LINE-STATUS-60
> AT ONBATT * START-TIMER BATT-STATUS-5 300
> AT ONBATT * START-TIMER BATT-STATUS-10 600
> AT ONBATT * START-TIMER BATT-STATUS-15 900
> AT ONBATT * START-TIMER BATT-STATUS-20 1200
> AT ONBATT * START-TIMER BATT-STATUS-25 1500
> AT ONBATT * START-TIMER BATT-STATUS-30 1800
> AT ONBATT * START-TIMER BATT-STATUS-60 3600
>
> when my bash script receive events from TIMER like? LINE-STATUS-xx
> NOTIFYTYPE is always ONBATT
>
> in all other cases, NOTYFYTYPE is TRUE and same as it was called by upsmon
>
> what is? wrong ?
>
> my parsed log for this situation :
> ===============
> Apr ?1 17:07:39 ?upsmon[652]: Onduleur UPS1 at localhost en mode Secours
> sur batterie
> Apr ?1 17:07:39 ?upssched[9126]: Executing command: ONBATT
> Apr ?1 17:07:39 ?upssched-cmd-received-NOTIFYTYPE: ONBATT
> Apr ?1 17:07:39 ?upssched[8783]: Cancelling timer: LINE-STATUS-5
> Apr ?1 17:07:39 ?upssched[8783]: Cancelling timer: LINE-STATUS-10
> Apr ?1 17:07:39 ?upssched[8783]: Cancelling timer: LINE-STATUS-15
> Apr ?1 17:07:39 ?upssched[8783]: Cancelling timer: LINE-STATUS-20
> Apr ?1 17:07:39 ?upssched[8783]: Cancelling timer: LINE-STATUS-25
> Apr ?1 17:07:39 ?upssched[8783]: Cancelling timer: LINE-STATUS-30
> Apr ?1 17:07:39 ?upssched[8783]: Cancelling timer: LINE-STATUS-60
> Apr ?1 17:07:39 ?upssched[8783]: New timer: BATT-STATUS-5 (300 seconds)
> Apr ?1 17:07:39 ?upssched[8783]: New timer: BATT-STATUS-10 (600 seconds)
> Apr ?1 17:07:39 ?upssched[8783]: New timer: BATT-STATUS-15 (900 seconds)
> Apr ?1 17:07:39 ?upssched[8783]: New timer: BATT-STATUS-20 (1200 seconds)
> Apr ?1 17:07:39 ?upssched[8783]: New timer: BATT-STATUS-25 (1500 seconds)
> Apr ?1 17:07:39 ?upssched[8783]: New timer: BATT-STATUS-30 (1800 seconds)
> Apr ?1 17:07:39 ?upssched[8783]: New timer: BATT-STATUS-60 (3600 seconds)
> Apr ?1 17:12:39 ?upssched[8783]: Event: BATT-STATUS-5
> Apr ?1 17:12:39 ?upssched-cmd-received-NOTIFYTYPE: ONBATT
> Apr ?1 17:13:06 ?upsd[7074]: Data for UPS [UPS1] is stale - check driver
> Apr ?1 17:13:09 ?upsmon[652]: Poll UPS [UPS1 at localhost] failed - Data stale
> Apr ?1 17:13:09 ?upsmon[652]: Perte de communication avec Onduleur
> UPS1 at localhost
> Apr ?1 17:13:09 ?upssched[9277]: Executing command: COMMBAD-INFO
> Apr ?1 17:13:09 ?upssched-cmd-received-NOTIFYTYPE: COMMBAD
> Apr ?1 17:13:09 ?upsd[7074]: UPS [UPS1] data is no longer stale
> Apr ?1 17:13:14 ?upsmon[652]: Retablissement des communications avec
> UPS1 at localhost
> Apr ?1 17:13:14 ?upsmon[652]: Onduleur UPS1 at localhost en mode Secteur :
> recharge batterie en cours
> Apr ?1 17:13:14 ?upssched[9307]: Executing command: ONLINE
> Apr ?1 17:13:14 ?upssched[9306]: Executing command: COMMOK-INFO
> Apr ?1 17:13:14 ?upssched-cmd-received-NOTIFYTYPE: COMMOK
> Apr ?1 17:13:14 ?upssched-cmd-received-NOTIFYTYPE: ONLINE
> Apr ?1 17:13:14 ?upssched[8783]: Cancelling timer: BATT-STATUS-10
> Apr ?1 17:13:14 ?upssched[8783]: Cancelling timer: BATT-STATUS-15
> Apr ?1 17:13:14 ?upssched[8783]: Cancelling timer: BATT-STATUS-20
> Apr ?1 17:13:14 ?upssched[8783]: Cancelling timer: BATT-STATUS-25
> Apr ?1 17:13:14 ?upssched[8783]: Cancelling timer: BATT-STATUS-30
> Apr ?1 17:13:14 ?upssched[8783]: Cancelling timer: BATT-STATUS-60
> Apr ?1 17:13:14 ?upssched[8783]: New timer: LINE-STATUS-5 (300 seconds)
> Apr ?1 17:13:14 ?upssched[8783]: New timer: LINE-STATUS-10 (600 seconds)
> Apr ?1 17:13:14 ?upssched[8783]: New timer: LINE-STATUS-15 (900 seconds)
> Apr ?1 17:13:14 ?upssched[8783]: New timer: LINE-STATUS-20 (1200 seconds)
> Apr ?1 17:13:14 ?upssched[8783]: New timer: LINE-STATUS-25 (1500 seconds)
> Apr ?1 17:13:14 ?upssched[8783]: New timer: LINE-STATUS-30 (1800 seconds)
> Apr ?1 17:13:14 ?upssched[8783]: New timer: LINE-STATUS-60 (3600 seconds)
> Apr ?1 17:18:14 ?upssched[8783]: Event: LINE-STATUS-5
> Apr ?1 17:18:14 ?upssched-cmd-received-NOTIFYTYPE: ONBATT
>
-- 
# admin linux only ;-)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/nut-upsuser/attachments/20250402/2308805b/attachment.htm>


More information about the Nut-upsuser mailing list