-
-
Notifications
You must be signed in to change notification settings - Fork 352
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
nut-driver-enumerator generates systemd service that pulls deprecated systemd-udev-settle #2638
Comments
Thanks! Looking at it, specifically at https://www.freedesktop.org/software/systemd/man/latest/systemd-udev-settle.service.html - I am not sure if there is an easy way forward. IIRC, the idea behind that dependency was to have NUT (USB-capable) driver programs start only after the OS has some certainty about available hardware (and supposedly assigns udev-based permissions), and this unit seems to be just about that. Can you try commenting away that dependency in your deployment and see if it works faster? I suppose in the field, if something is not yet discovered/assigned properly, a driver start-up attempt would fail and another (resuscitation) would succeed when everything settles on its own. In the graph above, |
Boot is indeed almost instant when I get rid of the
Starting the service by hand afterwards does work. Perhaps there might be an issue with the Eaton 5E specifically which causes it to be loaded slowly?
Doesn't seem to be the case; I grepped Regardless, I'm not too upset about the slower boot time. I don't reboot that often (unless troubleshooting anything else) and I'd rather have my components not get fried in case of some power outage :) The use of the deprecated |
One more idea to try (probably not a good one for "production", rather to see if there are visible differences): Keep the And The idea with this experiment is to delay NUT start-up until after the interactive system milestone is achieved (assuming it starts well at all). It has been a while, I am not sure which exact criteria systemd has to start units and targets beside making them wanted/required by common system units, so as to have a reason for NUT to start at all. I mean, manual Building on this experiment, if we stop at a half-way point, only commenting away the Overall, the goal is to have system intelligent power protection starting as early and running as long as possible.
More I suppose your "starting by hand" took place after more than that time since the initial failure to start (needing time for login, diagnosis and all that)? Is there anything interesting in Also,
Could be; however the documentation linked above suggests that "udev settling" waits for all hardware detection, not just the one item you might be interested in, and timing depends on the performance of the weakest link in the chain. Part of why it is not recommended for use, I guess. You can add debugging verbosity to the driver unit, see https://github.com/networkupstools/nut/wiki/Changing-NUT-daemon-debug-verbosity - to check which devices it sees during reboot, if the Eaton USB IDs (likely Alternatively, a |
Using Arch Linux, followed their wiki's guide for setting NUT: https://wiki.archlinux.org/title/Network_UPS_Tools
Eaton 5E 2000i USB. I applied the usbhid quirks kernel parameter.
After enabling the NUT enumerator to automatically generate, enable and start the UPS systemd service, my boot times have significantly slowed down:
My journal shows:
This in the enumerator script seems to be causing that:
nut/scripts/upsdrvsvcctl/nut-driver-enumerator.sh.in
Line 112 in 7dbf605
The text was updated successfully, but these errors were encountered: