Stratis

Siehe auch

Stratis setzt wie LVM auf den Device Mapper, ist aber für einfachere Anwendungsfälle gedacht und orientiert sich bei Bedienung und Konzepten an ZFS und Btrfs. So entfällt beispielsweise das Vergrössern des Dateisystems nach Hinzufügen von Storage Devices. Stratis setzt auf XFS (thin-provisioned). Das Kommandozeilenprogramm stratis arbeitet mit positionsabhängigen Parametern, lässt sich dadurch also elegant mit Bash-Completion nutzen.

Achtung

df kann Stratis-Pools nicht korrekt prüfen, da das Dateisystem thin-provisioned ist. So zeigt es immer 1 TiB grosse XFS-Dateisysteme an, egal wie gross diese tatsächlich sind. Es muss also stratis pool list verwendet werden.

# also installs stratisd
dnf -y install stratis-cli
systemctl enable --now stratisd

Umgang mit Stratis Pools (die Definitionen finden sich unter /dev/stratis/):

stratis pool create pool1 /dev/vdb
stratis pool add-data pool1 /dev/vdc

stratis pool list
stratis blockdev list pool1

Dateisystem verwalten:

stratis filesystem create pool1 fs1
# or shorter
stratis fs create pool1 fs1

stratis filesystem list
stratis filesystem destroy pool1 snapshot1

Umgang mit Snapshots:

stratis filesystem snapshot pool1 fs1 snapshot1
stratis pool list
mkdir /mnt/stratis/snapshot1
mount /dev/stratis/pool1/snapshot1 /mnt/stratis/snapshot1

Mount:

blkid /dev/stratis/pool1/fs1
mkdir -p /mnt/stratis/fs1
/etc/fstab
# delay mounting the file system until systemd starts the stratisd.service
# see `man systemd.mount`
UUID="..." /mnt/stratis/fs1 xfs defaults,x-systemd.requires=stratisd.service 0 0

Built on 2024-04-18