summaryrefslogtreecommitdiffstats
path: root/test/units/TEST-74-AUX-UTILS.mount.sh
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2025-01-14 16:49:52 +0100
committerLennart Poettering <lennart@poettering.net>2025-01-15 21:05:06 +0100
commit09fbff57fcde47782a73f23b3d5cfdcd0e8f699b (patch)
tree8756a640d0b620658f5fc36f794f6f373e771c28 /test/units/TEST-74-AUX-UTILS.mount.sh
parentpam-systemd: introduce "user-light" session type, and make "background-light"... (diff)
downloadsystemd-09fbff57fcde47782a73f23b3d5cfdcd0e8f699b.tar.xz
systemd-09fbff57fcde47782a73f23b3d5cfdcd0e8f699b.zip
pid1: add GracefulOptions= setting to .mount units
This new setting can be used to specify mount options that shall only be added to the mount option string if the kernel supports them. This shall be used for adding "usrquota" to tmp.mount without breaking compat, but is generally be useful.
Diffstat (limited to 'test/units/TEST-74-AUX-UTILS.mount.sh')
-rwxr-xr-xtest/units/TEST-74-AUX-UTILS.mount.sh7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/units/TEST-74-AUX-UTILS.mount.sh b/test/units/TEST-74-AUX-UTILS.mount.sh
index 89a391d48e..0700b43063 100755
--- a/test/units/TEST-74-AUX-UTILS.mount.sh
+++ b/test/units/TEST-74-AUX-UTILS.mount.sh
@@ -185,3 +185,10 @@ systemctl status "$WORK_DIR/mnt"
touch "$WORK_DIR/mnt/hello"
[[ "$(stat -c "%U:%G" "$WORK_DIR/mnt/hello")" == "testuser:testuser" ]]
systemd-umount LABEL=owner-vfat
+
+# Mkae sure that graceful mount options work
+GRACEFULTEST="/tmp/graceful/$RANDOM"
+systemd-mount --tmpfs -p GracefulOptions=idefinitelydontexist,nr_inodes=4711,idonexisteither "$GRACEFULTEST"
+findmnt -n -o options "$GRACEFULTEST"
+findmnt -n -o options "$GRACEFULTEST" | grep -q nr_inodes=4711
+umount "$GRACEFULTEST"