The steps for creating file system resources are described below. File system resources provide the capability to switch file systems on shared storage between cluster nodes. To create a replicated file system hierarchy using SIOS DataKeeper, see Creating a DataKeeper Resource Hierarchy.

System Configuration

The environment created in this guide is a two-node configuration as shown below.

To create file system resources, the following conditions must be satisfied:

  • Shared storage (e.g., iSCSI, Fibre Channel) is physically connected to each node
  • A file system has been created using a utility such as mkfs
  • The file system can be mounted/unmounted on each node

Perform the following steps on target1

  1. Mounting a file system
    Mount a file system for which you want to create a file system resource.
    In the example, /dev/sdb1 is mounted on /mnt/fs. The mount point is /mnt/fs.
[target1]# df
Filesystem              1K-blocks    Used Available Use% Mounted on
/dev/mapper/centos-root  14034944 6904924   7130020  50% /
devtmpfs                   929204       0    929204   0% /dev
tmpfs                      941312       0    941312   0% /dev/shm
tmpfs                      941312   25948    915364   3% /run
tmpfs                      941312       0    941312   0% /sys/fs/cgroup
/dev/sda1                  1038336 148528    889808  15% /boot
tmpfs                      188264       0    188264   0% /run/user/0
/dev/sdb1                  1044132  32992   1011140   4% /mnt/fs
  1. Creating a resource
    Run the following command.
[target1]# lkcli resource create fs --tag fs-tag --mountpoint /mnt/fs

Resource Settings

Item Input Value
--tag Tag name
--mountpoint Mount point
  1. Extending a resource
    Run the following command.
[target1]# lkcli resource extend fs --tag fs-tag --dest target2

Resource Settings

*Item Input Value
--tag Tag name of the created resource
--dest Backup node name
  1. Checking the resource
    After creating and extending the resource, run the following command.
    The resource information is displayed.
[target1]# lkcli status -q
 
LOCAL   TAG           ID                                   STATE     PRIO  PRIMARY
target1 fs-tag        /mnt/fs                              ISP          1  target1
target1  device28856  36000c292eb0c693b2efb44ed56556636-1  ISP          1  target1
target1   disk28786   36000c292eb0c693b2efb44ed56556636    ISP          1  target1

When you create a file system resource, multiple resources are automatically created with dependencies as shown above.


Feedback

Thanks for your feedback.

Post your comment on this topic.

Post Comment