Bugzilla – Bug 1219137
qemu user space builds broken with kernel 6.7
Last modified: 2024-01-24 14:09:20 UTC
Since commit 1c5976ef0f7a the kernel deregisters all binfmt_misc handler when the binfmt_misc filesystem is unmounted. The build script has this: # RPM specific post checks are in /usr/lib/build/checks if test -n "$RPMS" -a -d "$BUILD_ROOT/usr/lib/build/checks" ; then # workaround for broken 13.1 check scripts which umount /proc if test -n "$RUNNING_IN_VM" -a "$BUILD_ROOT" = / ; then umount -n $BUILD_ROOT/proc/sys/fs/binfmt_misc 2>/dev/null fi This means that after this point the emulation no longer works. [ 272s] ... checking for files with abuild user/group [ 272s] /.build/build: line 1922: /bin/env: cannot execute binary file: Exec format error [ 272s] /.build/build: line 1926: /bin/rpm: cannot execute binary file: Exec format error [ 272s] /.build/build: line 1926: /bin/rpm: cannot execute binary file: Exec format error [ 272s] /.build/build: line 1926: /bin/rpm: cannot execute binary file: Exec format error [ 272s] /.build/build: line 1926: /bin/rpm: cannot execute binary file: Exec format error [ 272s] /.build/build: line 1926: /bin/rpm: cannot execute binary file: Exec format error [ 272s] /.build/build: line 1926: /bin/rpm: cannot execute binary file: Exec format error [ 272s] /.build/build: line 1926: /bin/rpm: cannot execute binary file: Exec format error [ 272s] /.build/build: line 1926: /bin/rpm: cannot execute binary file: Exec format error [ 272s] /.build/build: line 1926: /bin/rpm: cannot execute binary file: Exec format error [ 272s] /.build/build: line 1926: /bin/rpm: cannot execute binary file: Exec format error According to the commit, this should be reported as a regression so that this behaviour is reverted for the initial binfmt_misc mount.
I have now switched openSUSE:Factory:RISCV to use an older kernel-obs-build, so builds can succeed again.
mls pushed an improved workaround for this for the build script. So we avoid this situation in future. (but keeping it open to let kernel people consider if they want to revert the behaviour change).
Please let me know when the updated build script has been deployed so that I can revert the kernel-obs-build workaround.