<feed xmlns='http://www.w3.org/2005/Atom'>
<title>packages/net/nut/files/nut_monitor, branch master</title>
<subtitle>Mirror of packages feed</subtitle>
<id>https://git.openwrt.org/feed/packages/atom?h=master</id>
<link rel='self' href='https://git.openwrt.org/feed/packages/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/feed/packages/'/>
<updated>2026-04-27T08:42:36Z</updated>
<entry>
<title>nut: ensure correct upsmon settings names</title>
<updated>2026-04-27T08:42:36Z</updated>
<author>
<name>Daniel F. Dickinson</name>
</author>
<published>2026-03-17T02:54:39Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/feed/packages/commit/?id=0c88118ad4bb303b811975925641357e69f6736b'/>
<id>urn:sha1:0c88118ad4bb303b811975925641357e69f6736b</id>
<content type='text'>
Prompted by
https://github.com/openwrt/luci/pull/8420#issuecomment-4071252681
we update upsmon configs to ensure they are correct according to
upstream. We reorder the options so that they match upstream
documentation at
&lt;https://networkupstools.org/docs/man/upsmon.conf.html&gt; to be sure
we have not missed any items.
While at it, we add configuration options from the upstream
documentation that are not currently present in the UCI configs.

Some years ago upstream changed the names the primary/secondary
UPS system/monitor from master/slave to primary/secondary. It
is uncertain how much longer these deprecated names will be
accepted by NUT.
Therefore update naming to match upstream documentation and
configuration. See
&lt;https://networkupstools.org/docs/man/upsmon.html&gt;,
&lt;https://networkupstools.org/docs/man/upsmon.conf.html&gt;, and
&lt;https://networkupstools.org/docs/man/upsd.users.html&gt;.

At the same time, prompted by
https://github.com/openwrt/packages/pull/28875#issuecomment-4079307540
we simplify the configuration and add checks to avoid bad configs
due to misspellings/typos of configuation options by users.

A sample config

config upsmon 'upsmon'
       option notifycmd '/usr/bin/logger -t nut-monitor-exec '

config monitor
        option type primary
        option upsname upsname
        option hostname localhost
        option username upsuser
        option password upspassword

config notifications 'ONLINE'
        option message "UPS %s is on line power"
        option flag "SYSLOG"

config notifications 'ONBATT'
        option message "UPS %s is on battery power"
        option flag "SYSLOG+EXEC"

In order to iterate through the notifications, we use named
'notifications' sections and compare the section name to list of
notification events defined by NUT. If they don't match, warn
during initscript startup.

Signed-off-by: Daniel F. Dickinson &lt;dfdpublic@wildtechgarden.ca&gt;
</content>
</entry>
<entry>
<title>nut: refactor nut-monitor uci config file</title>
<updated>2022-01-12T00:27:19Z</updated>
<author>
<name>Pascal Coudurier</name>
</author>
<published>2022-01-04T13:11:14Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/feed/packages/commit/?id=0f91594e2ae996f18e78ddc232340314d30c59cc'/>
<id>urn:sha1:0f91594e2ae996f18e78ddc232340314d30c59cc</id>
<content type='text'>
Convert notifyflags options to lists as supported by the init script, so multiple options can be chosen.
Add SYSLOG default option to individuals notifyflags instead of deprecated flag 1|0.
Add comment for defaultnotify and individuals notifyflags about possible values.

Signed-off-by: Pascal Coudurier &lt;coudu@wanadoo.fr&gt;
</content>
</entry>
<entry>
<title>nut: Reduce user error with POWERDOWNFLAG</title>
<updated>2018-08-29T04:17:19Z</updated>
<author>
<name>Daniel F. Dickinson</name>
</author>
<published>2018-08-27T20:41:17Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/feed/packages/commit/?id=a2f64b3bacc9a82bb149b1ac9fa0b8278000d2e4'/>
<id>urn:sha1:a2f64b3bacc9a82bb149b1ac9fa0b8278000d2e4</id>
<content type='text'>
Instead of making POWERDOWNFLAG an uci option the user can
only change it via initscript edits.  This avoids chance for users
to miss the required change to nut-driver when setting an UCI option
for nut-monitor which results in failure to do FSD on the UPS.

Signed-off-by: Daniel F. Dickinson &lt;cshored@thecshore.com&gt;
</content>
</entry>
<entry>
<title>nut: Use diff non-privileged user for upsmon</title>
<updated>2018-08-29T04:16:34Z</updated>
<author>
<name>Daniel F. Dickinson</name>
</author>
<published>2018-08-27T20:16:12Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/feed/packages/commit/?id=cf446c7c47ee6603cd473dbb99343481c4b5d596'/>
<id>urn:sha1:cf446c7c47ee6603cd473dbb99343481c4b5d596</id>
<content type='text'>
By default use a non-privileged user that is different than
the server or driver (when they are running non-privileged).
This is recommended by upstream.

Signed-off-by: Daniel F. Dickinson &lt;cshored@thecshore.com&gt;
</content>
</entry>
<entry>
<title>nut: Make FSD really work</title>
<updated>2018-08-29T04:15:14Z</updated>
<author>
<name>Daniel F. Dickinson</name>
</author>
<published>2018-08-27T20:33:25Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/feed/packages/commit/?id=918a62f91940a3e4b11a009442d8f085bf26075a'/>
<id>urn:sha1:918a62f91940a3e4b11a009442d8f085bf26075a</id>
<content type='text'>
Forced shutdown of the UPS was not actually happening before
due to lack of specific commands doing the shutdown.  This
(and the nut-driver initscript) fix that.

Signed-off-by: Daniel F. Dickinson &lt;cshored@thecshore.com&gt;
</content>
</entry>
<entry>
<title>nut: Use 'real' procd init for nut-monitor</title>
<updated>2018-08-29T04:14:20Z</updated>
<author>
<name>Daniel F. Dickinson</name>
</author>
<published>2018-08-27T20:28:47Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/feed/packages/commit/?id=f6a2a97d2f9561bbc57da7535fc718f0e3acbfb2'/>
<id>urn:sha1:f6a2a97d2f9561bbc57da7535fc718f0e3acbfb2</id>
<content type='text'>
This fully procdifies nut-monitor, which fixes some issues with
very slow restarts (due to /lib/functions/procd.sh using a very
long delay for non-native scripts doing restart) as well as gives
respawning, etc.

Signed-off-by: Daniel F. Dickinson &lt;cshored@thecshore.com&gt;
</content>
</entry>
<entry>
<title>net/nut: Build optional separate packages and ucify</title>
<updated>2017-01-11T23:53:58Z</updated>
<author>
<name>Daniel Dickinson</name>
</author>
<published>2017-01-11T23:53:58Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/feed/packages/commit/?id=a23c4e85c5f6c9f9dcf67743b93c492ba833e365'/>
<id>urn:sha1:a23c4e85c5f6c9f9dcf67743b93c492ba833e365</id>
<content type='text'>
With a LuCI app (of which I have one written) ucification makes
sense (and is in fact needed), so ucify the initscripts.

Also, rather than making selection of things to include an image
a matter of selecting compile-time config options, make optional
things into seperate packages that are built in default builds,
and leave selection of what to include or not up to the user
(e.g. using ImageBuilder, or adding packages via opkg).

Signed-off-by: Daniel Dickinson &lt;lede@cshore.thecshore.com&gt;
</content>
</entry>
</feed>
