Configuring a Shared File System resource

You can configure file system resources by using the clmgr command.

Prerequisites

To verify the Shared storage functionality, complete the following steps:
  1. Before you configure a filesystem, verify that disk is shared between the relevant nodes of cluster. File system resource cannot be added into resource group, which have some nodes in the node list where the disk of that filesystem is not shared. You can check the shared disk by using one of following command:
    1. lsrsrc -a -s "ResourceType==1" IBM.Disk
  2. Create a partition on the shared disk by using the fdisk /dev/<device> command. Complete the following steps:
    1. Use the variable n for new and d for delete option.
    2. Change the fd partition type by using the t option.
    3. In the end, save all updates by using the wq option.
  3. Create a physical volume on the partition by using the pvcreate <partition> command. You can list all physical volumes by using the pvdisplay option.
  4. Create a volume group on the partition by using the vgcreate <name of VG> <PV> [PV2….] command. You can list all volume groups by using the vgdisplay option.
  5. Create a logical volume on the partition by using the lvcreate –L <LV size with G or M designation> /dev/<name of VG> command. You can list all logical volumes by using the lvdisplay option.

Configuring

To configure the Shared storage functionality, complete the following steps:
  1. After you complete the prerequisite, check whether the logical volume is available on all the nodes of cluster by using the lvdisplay option or by using the clmgr query logical_volume command query.
  2. If the logical volume is not visible on all the nodes, run the partprobe command on all the nodes of cluster or try rebooting the nodes where the logical volumes are not visible.
After the logical volume is visible on all the nodes of cluster, configure a file system by using the following command:
clmgr add file_system  /home/fs_1 TYPE=ext3 LOGICAL_VOLUME="vg_1-lv_1"
Where, type is ext3, which is File System type, /home/fs_1 is name for the file system resource, and vg_1-lv_1 is the logical volume, which is shared among the nodes and must be present in clmgr query logical_volume command query.

After the file system is created, you can add it to resource group along with application. Filesystem alone can be configured in the RG in PowerHA® SystemMirror® Version 7.2.2 for Linux Service Pack 2 and later.

Then, change the resource group to an Online state.

Restrictions

Following are the restrictions to be followed when filesystem resource is added to RG
  1. FBHN RG policy must not be used if filesystem resource is configured in RG.
  2. If multiple filesystem resources are created on respective LVs on the same disk, then those resources must not be added in different Resource Groups.