Giter VIP home page Giter VIP logo

Comments (7)

dzomaya avatar dzomaya commented on June 4, 2024 1

Without digging into it (yet), my hunch is it is related to the fact the snmp-mibs-downloader is in a the "non-free" repo:
https://packages.debian.org/bullseye/snmp-mibs-downloader
Updating the apt sources list /etc/apt/sources.list might be a quick workaround (but that could be objectionable for a few reasons).

I'll circle back on this one over the weekend or next week.

from nutandrpi.

sebasdt avatar sebasdt commented on June 4, 2024 1

Hi,

Sorry for taking so to long to reply. Life just came right trough the door.

Anyway snmp has been installed successfully with the script after setting the source.list to non-free.
SNMP is working and displays the values correctly.
I cant seem to find the use case why snmp is better than using upsc directly to for example grafana.

The last problem the system is running into the UPS info website (ip.address/cgi-bin/nut/upsstats.cgi).
It aint showing nothing and displays this error:
Error: can't open template file (upsstats.html)
Before the reinstall it worked just fine.. could it be the reinstall removed a little too much?

well than this should be it, the last problem to solve.
Thank you for your time in advance!

from nutandrpi.

dzomaya avatar dzomaya commented on June 4, 2024 1

SNMP is working and displays the values correctly.

Great, thanks! I should consider adding to docs or something. For now, at least we have this reference.

I cant seem to find the use case why snmp is better than using upsc directly to for example grafana.

The SNMP use case is really for network monitoring tools (Observium, LibreNMS, etc). A lot of those tools use SNMP to communicate with a wide variety of devices. The Grafana case I toyed with a bit (there's a screenshot of that in the README), but didn't vet enough to make it part of this project (at least not yet).

It aint showing nothing and displays this error:
Error: can't open template file (upsstats.html)
Before the reinstall it worked just fine.. could it be the reinstall removed a little too much?

Seems like something went wrong with permissions. I'll need to mess around with it a little to give more precise advice. If I get some time during the week, I'll circle back. If I take too long, nudge me here!

It feels similar to this: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=249893 but I don't want to mislead with some FreeBSD specifics that might send you down a rabbit hole!

@sebasdt

from nutandrpi.

sebasdt avatar sebasdt commented on June 4, 2024 1

cool man!

Think it would be better if a new issue is opened for the "upsstats.html" error. Just to keep things clean and organized.
As for now it seems like upsstats.html is gone.
Trying to locate the file with:
find / -name "upsstats.*"

returns only there directories:
/usr/share/man/man8/upsstats.cgi.8.gz, /usr/share/man/man5/upsstats.html.5.gz, /usr/lib/cgi-bin/nut/upsstats.cgi

Also thank you for your help! Its the most useful I've gotten on a git issue.

edit:
Issue has been resolved. here below is the #9 solution
#9 (comment)

from nutandrpi.

dzomaya avatar dzomaya commented on June 4, 2024

I did some testing on a Debian 11 system (no UPS connected) and reproduced the issue. Then I uninstalled what the script installs (see: https://github.com/dzomaya/NUTandRpi#how-to-uninstall ; errors for uninstall of snmp-mibs-downloader are expected), added the non-free repos to /etc/apt/sources.list, ran apt update, and tried again. With the non-free repos enabled, snmp-mibs-downloader installed successfully when I ran the script again.

Here is what the /etc/apt/sources.list file that works looks like (I added all the non-free text you see, everything else is default):

deb http://deb.debian.org/debian bullseye main non-free
deb-src http://deb.debian.org/debian bullseye main non-free
deb http://security.debian.org/debian-security bullseye-security main non-free
deb-src http://security.debian.org/debian-security bullseye-security main non-free
deb http://deb.debian.org/debian bullseye-updates main non-free
deb-src http://deb.debian.org/debian bullseye-updates main non-free
deb http://deb.debian.org/debian bullseye-backports main non-free
deb-src http://deb.debian.org/debian bullseye-backports main non-free

@sebasdt
Is this a viable workaround for you?

from nutandrpi.

sebasdt avatar sebasdt commented on June 4, 2024

Nice! thank you for your work.
I will test it out later this week and let you know if it has worked!

from nutandrpi.

dzomaya avatar dzomaya commented on June 4, 2024

Also thank you for your help! Its the most useful I've gotten on a git issue.

That's great to read! Thank you for using the project!

from nutandrpi.

Related Issues (11)

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.