From 2803ce02a2cad4536472c52b98f049cd9dc415c4 Mon Sep 17 00:00:00 2001 From: Dominique Martinet Date: Tue, 21 Oct 2025 15:43:03 +0900 Subject: [PATCH] init: ignore error mounting cgroups In the spirit of #20 ignoring errors for debugfs, also ignore errors when the kernel is built without cgroups as we do not actually use the cgroups for anything in vmtest itself. Leave a log suggesting to enable the config like we do with debugfs. --- src/init/init.sh.template | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/init/init.sh.template b/src/init/init.sh.template index 9b7c46e..d64e148 100644 --- a/src/init/init.sh.template +++ b/src/init/init.sh.template @@ -67,7 +67,7 @@ log "Mounting tracefs at /sys/kernel/debug/tracing" mount -t tracefs tracefs /sys/kernel/debug/tracing || log "Failed to mount tracefs. CONFIG_DEBUG_FS might be missing from the kernel config" log "Mounting cgroup2 at /sys/fs/cgroup" -mount -t cgroup2 -o nosuid,nodev,noexec cgroup2 /sys/fs/cgroup +mount -t cgroup2 -o nosuid,nodev,noexec cgroup2 /sys/fs/cgroup || log "Failed to mount cgroups. CONFIG_CGROUPS might be missing from the kernel config" log "Mounting tmpfs at /mnt" mount -t tmpfs -o nosuid,nodev tmpfs /mnt