From: Daan De Meyer Date: Thu, 13 Feb 2025 13:41:21 +0000 (+0100) Subject: fmf: Don't fail if we can't modify sysctl values X-Git-Tag: v257.4~72 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=b207533cfe480e6b301fca990fd20d184f9c1108;p=thirdparty%2Fsystemd.git fmf: Don't fail if we can't modify sysctl values If the script is running unprivileged we might not be able to modify these so let's skip in that case. (cherry picked from commit 1e6514d6d047a19fe05fa53ed67ffce6d0012c31) --- diff --git a/test/fmf/integration-tests/test.sh b/test/fmf/integration-tests/test.sh index c5ba7507de8..c7aeb069989 100755 --- a/test/fmf/integration-tests/test.sh +++ b/test/fmf/integration-tests/test.sh @@ -13,9 +13,9 @@ lsmem echo "Clock source: $(cat /sys/devices/system/clocksource/clocksource0/current_clocksource)" -# Bump inotify limits so nspawn containers don't run out of inotify file descriptors. -sysctl fs.inotify.max_user_watches=65536 -sysctl fs.inotify.max_user_instances=1024 +# Bump inotify limits if we can so nspawn containers don't run out of inotify file descriptors. +sysctl fs.inotify.max_user_watches=65536 || true +sysctl fs.inotify.max_user_instances=1024 || true # Allow running the integration tests downstream in dist-git with something like # the following snippet which makes the dist-git sources available in $TMT_SOURCE_DIR: