Hi Nick,
On 19/07/2024 12:38, Nick Howitt wrote:
On 19/07/2024 10:21, Adolf Belka wrote:
Hi Michael & all,
nut has a command nut-scanner which scans for nut systems.
An IPFire user has used that command and it came back saying that it couldn't find the USB library libusb-1.0.so which is commented out in the rootfile.
It looks like nut when it is checking what libraries are available for the nut-scanner is looking for the .so files only and not the .so.0 or .so.0.3.0 files.
The same thing is occurring with avahi and netsnmp where nut is again only looking for the .so files, so in all three cases nut concludes that the usb, avahi and netsnmp libraries are not present even when they are.
It looks like no one has ever used the nut-scanner command and flagged up the issue as it will have had this problem for ever, as the libusb-1.0.so file has always been commented out (standard IPFire practice for rootfiles)
What should we do in this case when nut is only looking for the .so files. Should we uncomment the required .so libs?
The only alternative that I can see would be to comment out the command nut-scanner.
If we do uncomment the .so lib files mentioned above, how do we ensure that they stay uncommented and someone in the future does not see them and comment them out in the rootfiles.
I did that with nut about two years ago. I don't know now if that means that some of nut will not be properly working or not.
Should I now go an uncomment all the nut .so file entries in the nut rootfile?
Feedback and suggestions of the best approach for this gladly accepted.
Regards, Adolf.
Looking at the sources, https://github.com/networkupstools/nut.git, (which I can't really read), it looks like there is a config option, SOFILE_LIBUSB1 in https://github.com/networkupstools/nut/tree/master/tools/nut-scanner around lines 220 and onwards. Could nut be recompiled to use the so file? It would side-step the rootfile issue.
Thanks for that pointer. I will have a look at it and test it out and see how it goes.
Regards, Adolf.
Regards,
Nick