-
Notifications
You must be signed in to change notification settings - Fork 101
fix(host-preflights): builtin kernel modules file from wrong path #1741
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
fix(host-preflights): builtin kernel modules file from wrong path #1741
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, just a nit on logging the directories checked.
if _, err := os.Stat(kernelPath); os.IsNotExist(err) { | ||
klog.V(2).Infof("modules are not loadable because kernel path %q does not exist, assuming we are in a container", kernelPath) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: It might be worth logging in this instance that /lib/modules
does not exist, checking /usr/lib/modules
before the assuming we are in container
log fires, because that makes it sound like we only ever checked /usr/lib/modules
.
Or maybe update the kernelPath
in Infof
to be:
klog.V(2).Infof("modules are not loadable because kernel path %q or %q do not exist, assuming we are in a container", kernelPathLib, kernelPathUsr)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
updated to print the expected path
Description, Motivation and Context
Path is wrong for some systems.
Checklist
Does this PR introduce a breaking change?