From: Stefano Brivio <sbrivio@redhat.com>
To: Mateusz Andrzejewski <mandrzejewski06@gmail.com>
Cc: passt-dev@passt.top, piotr.bzdrega@mikronika.com.pl,
mateusz.andrzejewski@mikronika.com.pl
Subject: Re: [PATCH v2] isolation: Add --chroot-fallback option
Date: Wed, 08 Jul 2026 23:31:16 +0200 (CEST) [thread overview]
Message-ID: <20260708233111.67e8a533@elisabeth> (raw)
In-Reply-To: <20260702071526.2460400-1-mateusz.andrzejewski@mikronika.com.pl>
On Thu, 2 Jul 2026 09:13:31 +0200
Mateusz Andrzejewski <mandrzejewski06@gmail.com> wrote:
> For integrations, which use rootfs on tmpfs or initramfs, it is not
> allowed to use pivot_root(). It results with invalid argument (EINVAL)
> error. Introduce --chroot-fallback option as a workaround with
> MS_MOVE + chroot().
>
> Due to weaker isolation of chroot() method (we don't unmount old root),
> user has tu explicitly enable fallback with the new option. First,
> always try to sandbox with pivot_root(). In both cases the new root is
> placed into an empty tmpfs.
>
> For the solution to work we keep CAP_SYS_CHROOT capability, which is
> dropped at the end of the isolate_prefork() function.
>
> Link: https://bugs.passt.top/show_bug.cgi?id=104
>
> Signed-off-by: Mateusz Andrzejewski <mateusz.andrzejewski@mikronika.com.pl>
Applied (with minor tweaks as discussed), thanks, and welcome to the
git log!
--
Stefano
prev parent reply other threads:[~2026-07-08 21:31 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-02 7:13 Mateusz Andrzejewski
2026-07-04 15:27 ` Stefano Brivio
2026-07-06 8:06 ` Mateusz Andrzejewski
2026-07-08 21:31 ` Stefano Brivio [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260708233111.67e8a533@elisabeth \
--to=sbrivio@redhat.com \
--cc=mandrzejewski06@gmail.com \
--cc=mateusz.andrzejewski@mikronika.com.pl \
--cc=passt-dev@passt.top \
--cc=piotr.bzdrega@mikronika.com.pl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://passt.top/passt
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for IMAP folder(s).