Setting up storage with Stratis in just 5 minutes
Having used Fedora as my primary dev machine for over 2 years, I really appreciate its fast package updates. However, there was one “pain point”: every time I added a new hard drive, I had to struggle with LVM, partitioning, and formatting… which was extremely time-consuming. Everything changed when I discovered Stratis.
First, use DNF to install this toolset:
sudo dnf install stratisd stratis-cli
sudo systemctl enable --now stratisd
For example, let’s say I just plugged in a blank SSD at /dev/sdb. Here is the “quick and easy” process to upgrade your storage:
- Create a Pool: Group physical hard drives into a single management group.
sudo stratis pool create storage-pool /dev/sdb - Create a Filesystem: Initialize a data partition from the existing Pool.
sudo stratis filesystem create storage-pool data-work - Mount and use:
sudo mkdir /mnt/data sudo mount /stratis/storage-pool/data-work /mnt/data
In less than 5 minutes, you’ll have a storage system ready to go. No need to calculate block sizes or fuss with manual filesystem resizing like before.
Why is Stratis a “lifesaver” for Sysadmins?
Actually, Stratis isn’t a brand-new filesystem like Btrfs or ZFS. It’s more like a smart management layer (daemon) running on top of stable, established technologies like XFS, LVM, and Device Mapper.
The Power of Thin Provisioning
This is a feature I really love. With Stratis, the displayed filesystem size can be larger than the actual hard drive capacity. Data only takes up space when you actually write files.
Real-world example: You can create a 1TB virtual filesystem on just a 250GB SSD. As the data grows, Stratis allocates space on the fly, maximizing every GB of storage without worrying about wasting “reserved” space as with traditional partitioning.
Expandability in an Instant
Is /dev/sdb running out of space? Don’t worry. Just plug another drive, /dev/sdc, into the machine and add it to the existing Pool:
sudo stratis pool add-data storage-pool /dev/sdc
Immediately, all filesystems in storage-pool will have more “room to breathe.” You don’t need to umount or deal with annoying resize2fs commands.
Snapshots – Insurance for Your Data
As an Ops or Dev, accidentally typing rm -rf or breaking a config file is hard to avoid. Stratis snapshots are a “lifesaver” that lets you turn back time in an instant.
To create a snapshot for the data-work filesystem:
sudo stratis filesystem snapshot storage-pool data-work data-backup-$(date +%Y%m%d)
This snapshot operates completely independently. If you accidentally delete all data, just mount the backup and copy it back. I even use snapshots to test dangerous configurations; if things break, I can delete them and recreate from the original in seconds.
Auto-mount Configuration and “Hard-learned” Lessons
Important note: Never use device names like /dev/sdb in your /etc/fstab file. After a reboot, sdb could easily change to sdc, causing your system to fail immediately.
The best way is to use the UUID. You can get the Stratis filesystem UUID with this command:
lsblk -f
Then add it to /etc/fstab with the following mandatory options:
UUID=xxxx-xxxx-xxxx /mnt/data xfs defaults,x-systemd.requires=stratisd.service 0 0
The x-systemd.requires=stratisd.service option is a small but critical tip. It forces the OS to wait for the Stratis service to be ready before mounting the drive. Without this line, the machine could easily fall into Emergency Mode after a restart.
Practical Pro-tips: Checking System Health
To avoid surprises, you should regularly check the Pool status using Stratis’s intuitive command set:
stratis pool list: Monitor an overview of Pool capacities.stratis filesystem list: View the list of partitions and their actual space usage.stratis blockdev list: Check if the physical hard drives are “healthy.”
If you see strange information in the “Alerts” column, check the system logs immediately with journalctl -u stratisd to handle it promptly.
Conclusion
Although Fedora currently defaults to Btrfs, for large storage servers or workstations needing the stability of XFS combined with the flexibility of Pooling, Stratis remains an excellent choice. It simplifies administration to the maximum, allowing us to focus on code instead of wrestling with every byte of data on the drive.

