-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
udev fails to trigger loading of modules #11314
Comments
Does PR #11270 fix these issue? |
From https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=917185
Hmm... The reporter rebuild initramfs? |
Are there any chance to start |
Unfortunately, no... I guess the reporter just paste only lines which contain 'systemd-udevd'. Currently, udev workers do not append 'systemd-udevd' at the beginning of the journal log. So, the reporter log does not contain any udev worker's log. Relevant fix is waiting in #11244. |
I tried again, new logs attached to https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=917247#74 |
@gregoa there still seem some (initial) messages to be missing from a cursory glance. |
Hmm... |
@gregoa can you try with that patch applied? I can provide deb packages if it's too much hassle for you. @yuwata regarding this particular patch, I wasn't certain whether it's safe to pull, especially since that PR hasn't been merged yet. With all the back and forth regarding that bind/unbind problem, it wasn't immediately obvious if this revert is the right thing to do or not |
@mbiebl sure, I'll give it a try (tomorrow). |
@mbiebl My previous comment does not intend to backport the patch right now, sorry. Yeah, let's wait reviews. |
#11244 was merged. Let's close this, at least tentatively. If problem still exists, please reopen this. |
Adding b261494 on top of debian's 240-2 doesn't help, still the same failures. Logs at https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=917247#79 |
Hmm, there were also my changes in ebcc52f and related commits. Maybe they are the issue. |
BTW, the log provided by @gregoa does not contain, e.g., udevd processing 'acpi'. The first device processed by udevd is 'vcs2'. It seems quite strange for me. I am not sure whether it depends on the implementation of initramfs or not, but in my case, with dracut and plain systemd provided udev units, the first device is 'acpi'. |
@yuwata Please note that message 5 in the Debian bug report is not from me; I think in my prior logs (messages 45 and and 74), evdev was always present. |
@gregoa Ah, sorry for that... |
I am not familiar with the sysv init script, but it seems strange that it triggers only devices but not subsystems. But init-top/udev triggers both. Is it intended? |
@gregoa What happens if |
Wow. Looks like it just works; i.e. I have all modules back (and also no lvm warnings/timeouts). Thank you! |
Fwiw, this part of the sysv init script has basically been unchanged for years (it was actually written before I started (co) maintaining systemd). |
I've tried to create initrd by dracut without udevd: p.s. Even if all lines between |
And now I see that @lnussbaum already came to this conclusion.. welp, at least I learned something. |
@bikefrivolously and @lnussbaum Thank you for bisecting.
I've posted #11389. Could you test the PR? |
I can confirm that #11389 fixes the problem. |
I can also confirm that commit f90169d is enough to fix the problem |
Wow, thanks a lot! Which commit does fix this issue? |
Ah, I missed the previous comment. Thanks. |
v239 does not do that. But in v240, b1c097a and e39b4d2 make set buffer size with SO_RCVBUF. Still I do not know why that introduces systemd#11314. But, dropping that actually fixes the issue. So, let's simply revert the relevant changes made by those commits. Fixes systemd#11314.
@cankoluman and @ssolidus Thank you for testing the PR.
@mbiebl I hope you will be freed from such emails soon :-) |
By b1c097a (systemd#10239), the receive buffer size for uevents was set by SO_RCVBUF at first, and fallback to use SO_RCVBUFFORCE. So, as SO_RCVBUF limits to the buffer size net.core.rmem_max, which is usually much smaller than 128MB udevd requests, uevents buffer size was not sufficient. This fixes the ordering of the request: SO_RCVBUFFORCE first, and fallback to SO_RCVBUF. Then, udevd's uevent buffer size can be set to 128MB. This also revert 9038932. Fixes systemd#11314 and systemd#10754.
Finally I found the root of the issue. Please test the revised version (98aed1d). |
Fixed by #11389. |
Thank you for your help. |
Tested on Debian Buster VMware ESXi 6.7, and the patch seems to be working. I had to pull both EDIT: Thanks! |
BTW, I didn't properly express my thanks. v240-4 from Debian Sid contains this patch, and works fine for me. Thank you kindly. |
@ewhac Thank you for your help. |
c4b69e9 effectively moved the initalization of socket. Before that commit: run → listen_fds → udev_ctrl_new → udev_ctrl_new_from_fd → socket() After: run → main_loop → manager_new → udev_ctrl_new_from_fd → socket() The problem is that main_loop was called after daemonization. Move manager_new out of main_loop and before daemonization. Fixes systemd#11314 (hopefully ;)). v2: Yu Watanabe sd_event is initialized in main_loop(). (cherry picked from commit b5af8c8)
systemd version the issue has been seen with
v240
Used distribution
Debian sid
Since the update of systemd from v239 to v240, we had several downstream bug reports, where udev fails to trigger loading of kernel modules.
I think the following bug reports are basically all about the same underlying issue:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=917185
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=917247
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=917607
So far, all reports are either from users using udev with sysvinit or with udev in the initramfs (which doesn't use systemd in Debian). I wonder if there is a race condition in udev which is more likely to trigger with sysvinit or in the initramfs.
I wasn't able to reproduce the issue myself so far.
The udev SysV init script can be found at
https://salsa.debian.org/systemd-team/systemd/blob/master/debian/udev.init
The initramfs hooks to start udevd are at
https://salsa.debian.org/systemd-team/systemd/blob/master/debian/extra/initramfs-tools/scripts/init-top/udev
https://salsa.debian.org/systemd-team/systemd/blob/master/debian/extra/initramfs-tools/scripts/init-bottom/udev
Any hints on how to further debug this would be greatly appreciated.
The text was updated successfully, but these errors were encountered: