networkupstools / nut

The Network UPS Tools repository. UPS management protocol Informational RFC 9271 published by IETF at https://www.rfc-editor.org/info/rfc9271 Please star NUT on GitHub, this helps with sponsorships!
https://networkupstools.org/
Other
1.94k stars 346 forks source link

riello_ser driver does not support ondelay/offdelay #738

Open Skarafaz opened 4 years ago

Skarafaz commented 4 years ago

Hi!

I'm monitoring a Riello NDG1500 with nut 2.7.4 (debian package) using riello_ser driver. When I try to set ondelay/offdelay variables in ups.conf I get the error "variable not supported"; is this hardware related? I really need to set an off delay because my nas (a slave) takes about 5 minutes to shutdown. Thanks.

clepple commented 4 years ago

Per the protocol documentation, this should be supported by the hardware (NDG1500 uses the GPSER protocol): https://networkupstools.org/ups-protocols.html#_riello

However, it does not look like the driver implements any variables: https://github.com/networkupstools/nut/blob/v2.7.4/drivers/riello_ser.c#L758

clepple commented 4 years ago

The authors of the driver seem to have been working on a patch, but it stalled:

@CentroricercheRPS do you have a version of the patch with setvar?

clepple commented 4 years ago

@CentroricercheRPS Since the ups.delay.shutdown variable is sent at shutdown, and is not maintained in non-volatile memory on the UPS, @zykh's 2nd comment applies:

  • if they don't set values in the device, but only in NUT, add (and document in riello_{ser,usb} man pages) corresponding options to be set in ups.conf (or using the -x var=value command line option), since the driver, when launched with the -k flag or through upsdrvctl shutdown, cannot be aware of any 'transient' change made previously.
Skarafaz commented 4 years ago

Thanks for the support @clepple!

Skarafaz commented 4 years ago

@clepple just in case... what is the right way to deal with slow slaves without offdelay? Should I increase FINALDELAY variable in upsmon.conf?