From 5a0e19a52cfe74841cd5ba93b6f22b42d32f947a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vin=C3=ADcius=20Ferr=C3=A3o?= <2031761+viniciusferrao@users.noreply.github.com> Date: Fri, 16 Oct 2026 18:45:07 -0300 Subject: [PATCH] fix(genimage): create the /run mount point before mounting it mount_chroot bind-mounts the host /run into the image root before the run directory exists there. On the first build of a new image, mount fails with "mount point does not exist". genimage does not check the result, so the packages install without the host /run. Create the directory first, as mount_chroot already does for /proc, /sys and /dev. The mount also uses the subroutine argument instead of the global image path. Both have the same value at every call site. (cherry picked from commit 042804fe5ed93b2cba6fbca5984a5834274899c7) --- xCAT-server/share/xcat/netboot/rh/genimage | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/xCAT-server/share/xcat/netboot/rh/genimage b/xCAT-server/share/xcat/netboot/rh/genimage index 27585abbaa..89c0992420 100755 --- a/xCAT-server/share/xcat/netboot/rh/genimage +++ b/xCAT-server/share/xcat/netboot/rh/genimage @@ -113,7 +113,8 @@ sub mount_chroot { } if (-d "/run") { - system("mount --bind /run $rootimg_dir/run"); + system("mkdir -p $rootimage_dir/run"); + system("mount --bind /run $rootimage_dir/run"); } }