-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
[6.11 w/ CONFIG_RANDSTRUCT=y] sysctl table check failed #16620
Comments
It looks like this may be due to CONFIG_RANDSTRUCT being enabled. I had two builds, one with that enabled which generates the failure above and one with it disabled which lets the current build modprobe cleanly. This was working in 6.10 but I'm not certain what changed in 6.11 to break it. |
Thanks for the input. Will give it a try without CONFIG_RANDSTRUCT. |
Works without randstruct. Not a solution, but allows to boot 6.11 for now. |
Great. Finally I'm able to use ZFS on 6.11 kernels. Gentoo just removed all 6.10 sources... |
Might be an idea to update the title? Adding the modprobe error message "Protocol driver not attached" for searchability. |
This is kinda unfortunate that we have to sacrifice security feature for compatibility with ZFS, especially as it was working before on linux-6.6.x. I can try to bisect this to see what kernel commit triggers the issue. |
Bisected to this commit: commit d7a76ec87195ced6910b0ca10ca133bb316c90f5
Author: Joel Granados <[email protected]>
Date: Tue Jun 4 08:29:21 2024 +0200
sysctl: Remove check for sentinel element in ctl_table arrays
Use ARRAY_SIZE exclusively by removing the check to ->procname in the
stopping criteria of the loops traversing ctl_table arrays. This commit
finalizes the removal of the sentinel elements at the end of ctl_table
arrays which reduces the build time size and run time memory bloat by
~64 bytes per sentinel (further information Link :
https://lore.kernel.org/all/ZO5Yx5JFogGi%[email protected]/)
Remove the entry->procname evaluation from the for loop stopping
criteria in sysctl and sysctl_net.
Signed-off-by: Joel Granados <[email protected]>
fs/proc/proc_sysctl.c | 2 +-
net/sysctl_net.c | 11 ++--------- I can see openzfs still uses sentinel records at the end of each proc directory, e.g.
|
I tested that removal of sentinel records is indeed fixes the issue on 6.11: There should be proper guard for this changes as 6.10 still relies on sentinels. @robn do you know how to add the guard? I can add kernel version check, but it will not work for intermediate commits. |
Kernel 6.11-rc1 and later no longer use proc sentinel and zfs module will fail loading if compiled with CONFIG_RANDSTRUCT_PERFORMANCE=y The change makes the sentinels used only on earlier kernel versions. Ideally we should check for sentinels instead of kernel version. Signed-off-by: Ivan Volosyuk <[email protected]> Closes openzfs#16620
Kernel 6.11-rc1 and later no longer use proc sentinels and zfs module will fail loading if compiled with CONFIG_RANDSTRUCT_PERFORMANCE=y The change restricts use of the sentinel values to earlier kernel versions. Ideally we should check for sentinels instead of kernel version. Signed-off-by: Ivan Volosyuk <[email protected]> Closes openzfs#16620
Kernel 6.11-rc1 and later no longer use proc sentinels and zfs module will fail loading if compiled with CONFIG_RANDSTRUCT_PERFORMANCE=y The change restricts use of the sentinel values to earlier kernel versions. Ideally we should check for sentinels instead of kernel version. Closes openzfs#16620 Signed-off-by: Ivan Volosyuk <[email protected]>
Kernel 6.11-rc1 and later no longer use proc sentinels and zfs module will fail loading if compiled with CONFIG_RANDSTRUCT_PERFORMANCE=y The change restricts use of the sentinel values to earlier kernel versions. Ideally we should check for sentinels instead of kernel version. Closes openzfs#16620 Signed-off-by: Ivan Volosyuk <[email protected]>
Kernel 6.11-rc1 and later no longer use proc sentinels and zfs module will fail loading if compiled with CONFIG_RANDSTRUCT_PERFORMANCE=y The change restricts use of the sentinel values to earlier kernel versions. Ideally we should check for sentinels instead of kernel version. Closes openzfs#16620 Signed-off-by: Ivan Volosyuk <[email protected]>
Modprobing zfs fails with:
The text was updated successfully, but these errors were encountered: