Skip to content

Never attempt to mount the binfmt_misc filesystem

Emanuele Aina requested to merge wip/em/never-mount-binfmt-misc into apertis/v2021dev2

When installing qemu-user-static in a privileged Docker container update-binfmt --install mounts the binfmt_misc fs but then causes the installation to fail since it was not able to register the new entries.

This does happen on unprivileged containers since they don't have CAP_SYS_ADMIN so the mount() call fails, which update-binfmt handles nicely with a simple warning.

This patch forces update-binfmt --install to use the same codepath as update-binfmt --import which simply does not attempt to mount the binfmt_misc virtual filesystem.

Merge request reports

Loading