Skip to content

Conversation

@jimklimov
Copy link
Member

Bring updates from master, and apply similar code quality changes to DMF added code.

Marzal and others added 30 commits December 24, 2025 19:11
Tested with ExecCondition=/bin/sh -c '[ "$MODE" != "netclient" ]' an
Not sure if there is a better way to call `sh` without assuming a static dir.

Something like `command -v sh`
…BLE_EXEC_CONDITION@ and put ExecCondition for MODE values into more units; depend from NDE path units also on nut.conf changes; bump systemd integration copyrights [networkupstools#3233]

Signed-off-by: Jim Klimov <[email protected]>
…: rename nut-udev-settle.service into a .in template, handle ExecCondition here too [networkupstools#3233]

Signed-off-by: Jim Klimov <[email protected]>
… also consider "none" [networkupstools#3233]

Also fix nut-monitor.service (upsmon) to still start for a "netserver":
it is a full setup like "standalone", just with not only `localhost`
clients expected.

Signed-off-by: Jim Klimov <[email protected]>
Just launch nut-server systemd service if we are not on netclient mode
…inently the NUT CI farm hosting provider (and Fosshost, like Travis CI, is history) [networkupstools#2192]

Signed-off-by: Jim Klimov <[email protected]>
networkupstools#3244.

In drivers/huawei-ups2000.c, the serial port is opened twice. Once by
ser_open() to manually perform device identification, once by
modbus_connect() for communicating with the UPS after identification
succeeds.

However, holding two file descriptors of the same serial port is
problematic on Windows, even if they're not actually used at the same
time. A serial port is usually opened on Windows via CreateFileA() with
dwShareMode = 0, which is done by libmodbus. According to the Win32
API documentation:

> If this parameter is zero and CreateFile succeeds, the file or device
> cannot be shared and cannot be opened again until the handle to the
> file or device is closed.

This is responsible for the following error on Windows:

    modbus_connect: unable to connect: No error
    Driver failed to start (exit status=1)

This commit leaves only the raw ser_open() call in upsdrv_initups(),
the modbus_connect() call is deleted to avoid opening the same serial
port again. After device identification succeeds later in
ups2000_device_identification() - called by upsdrv_initinfo(), the raw
serial port is closed. Once at this point, modbus_connect() is called,
just before upsdrv_initinfo() returns.

Signed-off-by: Yifeng Li <[email protected]>
…: fix "nobattery" alarm on OpenUPS devices [networkupstools#3246]

Signed-off-by: Jim Klimov <[email protected]>
…-port-fix

drivers/huawei-ups2000.c: call ser_close() before modbus_connect(), fix networkupstools#3244.
…of Microsoft IIS to host the NUT CGI programs [networkupstools#3207]

Signed-off-by: Jim Klimov <[email protected]>
…-in CONFPATH [networkupstools#3207]

Already done for other files, only hosts.conf was seeked wrongly.

Signed-off-by: Jim Klimov <[email protected]>
…ath() rather than built-in CONFPATH, and document the (incomplete) *mib.conf support

Signed-off-by: Jim Klimov <[email protected]>
…mic confpath() rather than built-in CONFPATH

Signed-off-by: Jim Klimov <[email protected]>
…an/upsset.conf.txt, NEWS.adoc, docs/nut.dict: introduce --with-cgi-uri [networkupstools#3207]

Signed-off-by: Jim Klimov <[email protected]>
…rt on WIN32 builds [networkupstools#3207]

Let CGI work under IIS with `\\?\c:\...` paths to config files.
TOTHINK: Maybe move this closer to GetModuleName() calls?

Signed-off-by: Jim Klimov <[email protected]>
@jimklimov jimklimov force-pushed the FTY-remerge-20260116 branch from 6f3cf7e to 9b1d124 Compare January 16, 2026 14:05
@AppVeyorBot
Copy link

jimklimov and others added 13 commits January 17, 2026 13:30
Add missing data points for Goldenmate to iDowell subdriver
…wly Goldenmate) devices on USB ID v075Dp0300 [networkupstools#3265]

Signed-off-by: Jim Klimov <[email protected]>
…p to report battery.voltage [networkupstools#2766]

Authored-By: Vladyslav Andreichykov <[email protected]>
Signed-off-by: Jim Klimov <[email protected]>
…S-ERA-PLUS-2000

Add UPS model 'UPS ERA PLUS 2000' to driver list
Several small fixes contributed out of PR stream
@AppVeyorBot
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

DMF NUT Data/Dynamic Mapping File/Format/Functionality feature SNMP

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants