In our previous guide, we have seen how to install and create Stratis layered storage pool and file systems. Now let us see how to manage Stratis by adding new disks to the existing pool and adding cache disk. By following will cover with removing pools and file system.

Read more about Stratis layered storage:

Adding additional disk to the pool

Its super easy to add a new block device to existing pool under stratis management. In our setup we have 4 disks in “data01_pool“, now we required to extend the space in the pool by adding a new disk. Use option “add-data” to add a new disk.

# stratis pool list
# stratis pool add-data data01_pool /dev/sdf
Adding additional disk to existing pool in stratis
Adding additional disk to existing pool in stratis
# stratis pool list

In the above figure we can notice before adding a disk its total physical size is “8 TB”, And after adding a “2 TB” disk the size has been extended to “10 TB”.

  1. Listing the existing stratis pools.
  2. Adding additional disk to existing pool.
  3. Device we are about to add into existing pool.
  4. Total size of the pool after adding a new disk.

Adding a Cache disk to Stratis pool

To improve the performance of storage stratis provided with an option to add a cache disk. Caching can be configured for redundancy or non-redundancy, write-back and write-through modes. This step will be similar to adding a additional disk by replacing option “add-cache”.

# stratis blockdev list
# fdisk -l /dev/sdg
Adding Cache disk to Stratis pool
Adding Cache disk to Stratis Pool
# stratis pool add-cache data01-pool /dev/sdg
# stratis blockdev list
  1. Existing list of block devices under pool.
  2. 500 GB Disk we are about to add in pool.
  3. Adding a cache disk using option “add-cache”.
  4. Added cache disk in data pool.

Renaming Pools and file systems

Stratis have the feature to rename a pool or filesystem on the fly without impacting any running setup. In case if we need to rename the pool its quite easy by running a single command with options and arguments.

Let us rename our current pool name “data01_pool” to “data01_pool_old”.

# stratis pool list
# stratis pool rename data01_pool data01_pool_old
# stratis pool list
Renaming Pools
Renaming Pools
  1. Current Pool name need to be renamed.
  2. The new name of the pool we are about to rename.
  3. Pool name after renamed.

Let us see how to rename the file System.

Renaming a file system is similar to renaming a pool. Only we need to replace the option “pool” and “filesystem” and make sure to use the correct names of pool and FS if you have multiple numbers in your server.

Renaming filesystem in Stratis
Renaming filesystem in Stratis

Removing a Stratis filesystem

Managing Stratis storage by removing a file system, Initially we need to remove the fstab entry, by following un-mount the file system.

# vi /etc/fstab
# umount /user_data02

After un-mounting the file system, we need to use the correct pool name with the file system which needs to be removed.

# stratis filesystem list
# stratis filesystem destory data01_pool user_data02
Destroy a file-system from stratis pool
Destroy a file-system from stratis pool
  1. Unmount the file system.
  2. List the file systems created using Stratis.
  3. Choose the file system we need to destroy.
  4. Use destroy” option with stratis command.
  5. List to verify the destroyed file system.

Removing a Stratis Pool

To remove a Stratis pool we should remove the file system created under it. In case if we try to remove a pool without destroy the FS it will throw error similar to below.

[root@linuxsysadmins ~]# stratis pool destroy data01_pool_old 
Execution failure caused by:
BUSY: filesystems remaining on pool

List the available pool and destroy it.

# stratis pool list
# stratis pool destroy data01_pool_old
# stratis pool list
Destroy Pool in Stratis
Destroy Pool in Stratis
  1. List to verify.
  2. Destroy the pool.
  3. Again list to verify the status.

Create a Snapshot in Stratis

Stratis comes with a major required solution to take a snapshot of any file system. Let us take a snapshot of existing file System in our server.

# stratis filesystem list
# stratis filesystem snapshot data01_pool_old user_data01 user_data01_snapshot
# stratis filesystem list data01_pool_old
Snapshot a filesystem in Stratis
Snapshot a filesystem in Stratis

That’s it, Managing a layered storage system Startis is easy than any other storage management tools.

Conclusion:

We have seen how to manage Stratis storage by adding disks and renaming them. In our future article will cover with more Stratis topics. Subscribe to our newsletter and give your feedback or query in below comment section.

Babin Lonston
Overall 14+ Years of experience in IT field, 7+ years of experience in Linux administration with Virtualization & Cloud technologies. Love documentation and being Numismatics for a long time.

Stratis to create layered storage in RedHat Enterprise Linux 8

Previous article

Creating Software RAID and Volumes on Openfiler Storage

Next article

You may also like

2 Comments

  1. How can I move data to another physical disks? For example, I need to migrate data to a new SAN.

    Thank you very much.

    1. @David, For time being Stratis not came up with those feature than listed above, Soon they will bring more added features. Will update the articles once we get one.

      Thanks & Regards,
      Babin Lonston

Leave a reply

Your email address will not be published.