| SYSTEMD-MSTACK(1) | systemd-mstack | SYSTEMD-MSTACK(1) |
NAME
systemd-mstack, mount.mstack - Mstack Discoverable Disk Images (DDIs)
SYNOPSIS
systemd-mstack [OPTIONS...] IMAGE
systemd-mstack [OPTIONS...] [--mount] IMAGE PATH
systemd-mstack [OPTIONS...] [--umount] PATH
DESCRIPTION
systemd-mstack is a tool for introspecting and interacting with .mstack/ mount stack directories, as described in systemd.mstack(7). It supports three different operations:
The systemd-mstack command may be invoked as mount.mstack in which case it implements the mount(8) "external helper" interface. This ensures mount stack directories compatible with systemd-mstack can be mounted directly by mount and fstab(5). For details see below.
In place of the image path a ".v/" versioned directory may be specified, see systemd.v(7) for details.
COMMANDS
If neither of the command switches listed below are passed the specified mount stack is opened and general information about it is shown, including a list of all defined layers.
--mount, -m
To unmount a mount stack directory mounted like this use the --umount operation.
Note that this functionality is also available in mount(8) via a command such as mount -t mstack mystack.mstack targetdir/, as well as in fstab(5). For details, see below.
Added in version 260.
-M
Added in version 260.
--umount, -u
All mounted mounts will be recursively unmounted
Added in version 260.
-U
Added in version 260.
-h, --help
--version
OPTIONS
The following options are understood:
--read-only, -r
Added in version 260.
--mkdir
Added in version 260.
--rmdir
Added in version 260.
--image-policy=policy
--image-filter=filter
--no-pager
--no-legend
--json=MODE
EXIT STATUS
On success, 0 is returned, a non-zero failure code otherwise.
INVOCATION AS /SBIN/MOUNT.MSTACK
The systemd-mstack executable may be symlinked to /sbin/mount.mstack. If invoked through that it implements mount(8)'s "external helper" interface for the (pseudo) file system type "mstack". This means conformant mount stack directories may be mounted directly via
# mount -t mstack mystack.mstack targetdir/
in a fashion mostly equivalent to:
# systemd-mstack --mount mystack.mstack targetdir/
Note that since a single mount stack may contain multiple mount points it should later be unmounted with umount -R targetdir/, for recursive operation.
This functionality is particularly useful to mount mount stacks automatically at boot via simple /etc/fstab entries. For example:
/path/to/mystack.nspawn /images/mystack/ mstack defaults 0 0
When invoked this way the mount options "ro", "rw" map to the corresponding options listed above (i.e. --read-only).
SEE ALSO
systemd(1), systemd.mstack(7), systemd-nspawn(1), systemd.exec(5), mount(8), umount(8)
| systemd 260.1 |