-
Notifications
You must be signed in to change notification settings - Fork 30
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
init: Use pivot_root, not chroot #19
Comments
Line 282 in c8e79b7
pivot_root ). I don't know if this has changed, but Linux docs suggest not.
|
Thanks, sorry for not reading the comment above. I'm fine to close this as WONTFIX. BTW, I think now that Linux supports root-on-virtiofs we could basically obsolete the supermin disk image building and this code I believe? |
virtiofs is quite a bit more heavyweight than some files zipped up into a cpio. It involves running a daemon at least.
|
The difference becomes visible when a process in a different mount namespace wants to enter the original mountns. |
Note also the use of
This is by design (thanks @giuseppe for the link): https://github.com/torvalds/linux/blob/41bccc98fb7931d63d03f326a746ac4d429c1dd3/kernel/user_namespace.c#L98-L107 |
See containers/bootc#203
TL;DR using
chroot
instead ofpivot_root
breaks things that want to enter the root mountns from a different mount namespace.The text was updated successfully, but these errors were encountered: