-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
selinux keycreate issue #5864
Comments
It looks like you're running an older version of containerd and runc ( |
I suppose that is worth a try, i didnt know about 1.4.9, as 1.4.6 was newest last I checked.
also I noticed they have the same value here:
|
trying it right now and will update with results. |
Thanks! I definitely don't know if it will resolve the issue, but just in case (I know there were some fixes in runc 1.0.1 around SELinux handling) |
unfortunately I'm still seeing it:
although actually it grabbed crun? heres the relevant versions:
edit: wait actually runc is there:
i guess it just wasn't a package listed in dnf, this is unfortunate as, for some of us disabling selinux isn't an option. and of the bigger updates in containerd 1.4 was better selinux support (like for actual contexts/labeling, and such) |
I may have figured out something, let me try to verify it with some trial and error likely ill have something by tomorrow morning. |
Ok so I think I may have figured this out and can probably close the issue. I don't think the ball is in containerd's court in this case unless they want to handle this exception and possibly present it differently (if thats even possible). But I think its worth explaining for future users who run into this. The error here appears to be misleading, because it LOOKS like the same from the issues I linked in the original post. However,
might be key. I noticed that which containers got this was changing, namely, increasing, and then decreasing (after I became suspicious in my last post). The correlation was providing an selinux context that doesn't exist. I had removed the policy but forgot to remove the pod manifest entry instructing it to use the selinux context. in other words you get this if you try to give a container/pod selinuxOptions type that doesn't exist. let me know if you think we can close this issue, or if containerd is interested in it in some way shape or form, but doesn't seem to be a containerd issue to me. |
Good to hear you found the cause! As to the error message; all errors after
I agree those errors are quite verbose, but not really helpful either. Not sure if runc would have more information available to produce a better error, but if you have an easy way to reproduce, it might be worth opening a ticket in the runc repository; https://github.com/opencontainers/runc |
Let me close this ticket per the above, but feel free to continue the conversation |
seems to be an issue stemming from container-selinux is occurring in rhel8 if installing containerd. Ive noticed in Rhel7 folks say to update container-selinux.
docker/for-linux#983
moby/moby#39109
I'm getting it in Rhel8, my guess is that the container-selinux that comes with containerd might be one that doesn't have the fix mentioned. I think this is noteworthy because many will attempt to follow these instructions for their containerd installation:
https://kubernetes.io/docs/setup/production-environment/container-runtimes/#containerd
I guess it depends on what exactly the container is trying to do because not all of them get it.
Steps to reproduce the issue:
Describe the results you received:
some containers get this error:
Error: failed to create containerd task: OCI runtime create failed: container_linux.go:380: starting container process caused: process_linux.go:545: container init caused: failed to set /proc/self/attr/keycreate on procfs: write /proc/self/attr/keycreate: invalid argument: unknown
Describe the results you expected:
should start up like the other containers
What version of containerd are you using:
Any other relevant information (runC version, CRI configuration, OS/Kernel version, etc.):
runc --version
selinux enabled/true
crictl info
uname -a
uname -a
Linux ip-10-42-32-9.ec2.internal 4.18.0-305.12.1.el8_4.x86_64 #1 SMP Mon Jul 26 08:06:24 EDT 2021 x86_64 x86_64 x86_64 GNU/Linux
probably also useful:
and dnf does not seem to think theres an upgrade for this available for a newer version. In the links above they are talking about versions like 2.9
The text was updated successfully, but these errors were encountered: