Code Monkey home page Code Monkey logo

Comments (6)

jimklimov avatar jimklimov commented on June 3, 2024

Hello, and thanks for your report.

One thing that comes to mind is https://github.com/networkupstools/nut/wiki/CyberPower-Systems-(CPS)-know-how bit that shutdown times in CPS firmware are often discretely floored down to whole minutes - so a 30 sec setting becoming a 0 for instant shutdown seems to match. 300 sec becoming one minute does not, however, so maybe there's something else at play.

For debugging suggestions there's https://github.com/networkupstools/nut/wiki/Changing-NUT-daemon-debug-verbosity and please do generally note that your NUT v2.7.4 is a pretty old release (8 years now) so it is possible the current code base behaves better. Can't remember of any changes specifically about shutdown times though, but at least troubleshooting friendliness should be better :)

https://github.com/networkupstools/nut/wiki/Building-NUT-for-in%E2%80%90place-upgrades-or-non%E2%80%90disruptive-tests suggests how you can build current NUT to test new driver binary from the build workspace, then maybe install over your package-delivered NUT if testing results are satisfactory.

from nut.

NoPlayBack avatar NoPlayBack commented on June 3, 2024

Thanks for the answer....
i do use NUT on a RaspberryPi and simply did run
"sudo apt install nut nut-client nut-server"
I did more or less follow these funny & entertaining but very useful instructions: https://technotim.live/posts/NUT-server-guide/
which is obviously being updated often (currently few days ago).
So i am totally surprised, when you are saying i am running on old and outdated stuff !!!

What did i do wrong, and how can i get newest versions ?????

(Have just right now checked... i am still seeing 2.7.4 as latest available version (using apt policy nut-server))

from nut.

jimklimov avatar jimklimov commented on June 3, 2024

Probably you are using an older distro, or one with stricter policy about updating packages from the version they originally shipped (fair enough, new code may mean new bugs). In Debian land, you'd need "sid" or "unstable" for recent-ish packages; I think Debian 12 should have shipped with NUT 2.8.0 at least.

You did not mention an OS running on the Raspberry though, but usually it is a Debian or Ubuntu derivative. Building your own NUT from current codebase should be simple, per wiki. Or a bit more complex if you endeavour to find the configure arguments used by your exact OS/distro release' package recipes and so produce a perfect replacement :)

Also note that Raspberries popped up fairly often in the past few years of issues, mostly in regard to connection stability issues. Maybe this just reflects popularity of the platform (more uses => more reports), but maybe some flakiness in its hardware. Hearsay goes that USB stability on Pi3 was problematic, Pi4 fixed it, Pi5 may have other issues again.

from nut.

NoPlayBack avatar NoPlayBack commented on June 3, 2024

Running this here:

pi@raspberrypi01:~ $ cat /etc/os-release
PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)"
NAME="Raspbian GNU/Linux"
VERSION_ID="11"
VERSION="11 (bullseye)"
VERSION_CODENAME=bullseye
ID=raspbian
ID_LIKE=debian
HOME_URL="http://www.raspbian.org/"
SUPPORT_URL="http://www.raspbian.org/RaspbianForums"
BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"

Well, while i'm fairly able to walk my way through installing packages, configuring and using them, and while i was able to find my way through setting up iobroker, mysql, grafana, vis, and some pieces of python code, i simply struggle to find my way into details of NUT. And i am wondering why. It is not the first time that i am told i am using very old stuff (using WinNut-Client V2.2.8719.24624) but with using your links above i do not really find instructions for doing that, it seems as if i find my way into source-code repositories, and i am asked to build and compile the stuff i need myself.
Am i looking in the wrong areas or is this the truth?
I really would like to get NUT running, and i would really be happy to support this community with information about the new CP1600EPFCLCD from Cyberpower, but i am failing.

from nut.

jimklimov avatar jimklimov commented on June 3, 2024

Yes, those links to Wiki above (and further into NUT docs) are about building NUT from source - some detail which prerequisite packages you need to install on this or that OS, others outline the steps needed for actual compilation, testing from the build workspace, and possibly installation over whatever your OS packages delivered previously.

That's the best balance we could come up with for getting people able to run NUT everywhere vs. tracking all the hundreds of distros it can run on (and many of those we've never heard about until mention on the issue tracker) and trying to package it for everything ourselves. Distro maintainers do a better job at that, but often according to some policy which balances their workload and codebase stability of packages. Some deliberately take code, say, at least 3 months or 1 previous release old, so as to avoid being first to discover some baby errors.

from nut.

NoPlayBack avatar NoPlayBack commented on June 3, 2024

Need to correct my first statement.... about functionality of instant commands.
I did test

beeper.disable - Disable the UPS beeper
beeper.enable - Enable the UPS beeper
load.off.delay 30 - Turn off the load with a delay (seconds)
load.on.delay 30 - Turn on the load with a delay (seconds)
load.on - Turn on the load immediately

and from that point on i did get

usbhid-ups[5347]: libusb_get_interrupt: error sending control message: Operation not permitted
usbhid-ups[5347]: libusb_get_interrupt: error sending control message: Broken pipe
usbhid-ups[5347]: libusb_get_interrupt: error sending control message: Broken pipe
usbhid-ups[5347]: libusb_get_interrupt: error sending control message: Broken pipe

in syslog.

So the tests results may be wrong.
Definitely wrong is my statement about

shutdown.return - Turn off the load and return when power is back

which i tested while the error messages were running in.

Tested it yesterday again at it works as expected.

  • If power is available, then the system switches off immediately and switches back on after approximately 6 sec.
  • If power is gone, then the system switches off immediately, goes to sleep after few seconds, seems as if it also stops communications on USB. Then, with power back on, it switches on after approximately 6 sec.

from nut.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.