Setting up asynchronous GLVM

By default the Geographic Logical Volume Manager (GLVM) packages are installed in the AIX® operating system.

Prerequisites

  • Ensure that your system is running on AIX version AIX 7 with 7200-04, or later.
  • Ensure that you are using TCP/UDP port 6192 across the primary and secondary sites for communication.
  • Ensure that you have sufficient disks for creating the remote physical volume (RPV) server and RPV clients.
To set up the asynchronous GLVM, complete the following steps:
  1. Configure the RPV server and RPV clients by using the SMIT glvm_utils fast path, as follows:
    1. To create an RPV server, select Remote Physical Volume Servers > Add Remote Physical Volume Servers, and then press Enter.

      For more information about creating the RPV server and RPV clients in PowerHA® SystemMirror® for AIX, see Configuring geographically mirrored volume groups.

    2. To define an RPV site name, select Remote Physical Volume Servers > Remote Physical Volume Server Site Name Configuration > Define / Change / Show Remote Physical Volume Server Site Name, and then press Enter.
    3. To create RPV client, select Remote Physical Volume Clients > Add Remote Physical Volume Clients, and then press Enter
  2. Create an asynchronous volume group that can be used with the GLVM, by completing the following steps:
    1. Create a scalable volume group by running the following command:
      mkvg -f -S -y agmvg hdisk5 hdisk15

      When you run this command, the asynchronous agmvg volume group is created. The volume group has two disks, hdisk5 and hdisk15.

    2. Create a mirror pool for the disks that are associated with the asynchronous volume group by running the following command:
      chpv -p mp1 hdisk5 hdisk15

      When you run this command, a mirror pool mp1 is created for the hdisk5 and hdisk15 disks.

      1. Now, extend the asynchronous volume group to include other disks that might be created when you configure the RPV server and RPV clients in the node of the primary site.
        extendvg -f -p mp2 agmvg hdisk22 hdisk23

      When you run this command, the agmvg asynchronous volume group is extended to include hdisk22 and hdisk23 disks. The mirror pool mp2 is also created.

    3. Create a logical volume (glv) for the agmvg asynchronous volume group by running the following command. The file system of the logical volume consists of files that are part of data logical volume and log logical volume.
      • Create data logical volume by running the following command:
        mklv -t jfs2 -y glv -p copy1=mp1 -b n -s s -u 1 agmvg 10
      • Create log logical volume by running the following command:
        mklv -t jfs2log -y glv_log -p copy1=mp1 -b n -s s -u 1 agmvg 10
    4. Create a journaled file system (JFS2) file system that must be used for the data logical volume and log logical volume by running the following command:
      crfs -v jfs2 -A no -m /gfs -d glv -a logname=glv_log
    5. Create a mirror copy of the asynchronous volume group in the RPV server and the RPV client.
      mirrorvg -c 2 -p copy2=mp2 agmvg
      All data from mirror pool mp1 (disks in the primary site) is copied to the mirror pool mp2 (remote disks in the secondary site) in synchronous mode over the standard TCP/IP network.
    6. Create cache logical volumes for caching asynchronous volume group write requests by running the following commands.
      mklv -t aio_cache -y mp1_cache -p copy1=mp1 -b n agmvg 5 hdisk5        
      mklv -t aio_cache -y mp2_cache -p copy1=mp2 -b n agmvg 5 hdisk23

      These cache logical volumes must not be mirrored across sites. You can create mirror pools by using the super strict disk allocation policy that can manage the new aio_cache logical volumes.

    7. Configure the asynchronous mirroring properties of the cache logical volumes and the secondary site to specify the maximum capacity for write requests before new write requests must wait for mirroring to the remote disks.
      • Configure asynchronous mirroring properties of the cache LV by running the following command:
        chmp -A -h 80 -m mp2 agmvg  
      • Configure asynchronous mirroring properties of the secondary site by running the following command:
        chmp -A -h 50 -m mp1 agmvg        
      • Verify whether the chmp command is successful by running the following command:
        lsmp agmvg

    After you configure asynchronous mirroring properties, if the state of the mirror pool reaches the asynchronous state and the mirror pool is active, remote I/O operation requests are written to the cache logical volume (cachelv) and then the I/O operation requests are mirrored from the cachelv to the secondary site. You can then mount the file system of the logical volume in the secondary site to start the application that is mirrored from primary site to secondary site.

  3. Verify the asynchronous GLVM setup by performing the following steps:
    • Ensure proper network connectivity and ensure that the state of the physical volume (PV) disk is active by running the following command:
      # lsvg -p agmvg
      
      An output that is similar to the following example is displayed:
      
      agmpvg:
      PV_NAME  PV_STATE TOTAL_PPs FREE_PPs FREE DISTRIBUTION
      hdisk6   active   957       627      192..00..52..191..192
      hdiskl   active   957       937      192..171..191..191..192
      hdisk8   active   951       617      192..00..42..191..192
      hdisk9   active   951       947      192..181..191..191..192
    • Monitor the asynchronous I/O operation requests and the number of connections that are active in the GLVM environment, by running the following command:
      rpvstat -A
      An output that is similar to the following example is displayed:
      Remote Physical Volume Statistics: 
                         Completed       Completed    Cached      Cached    Pending  Pending 
                         Async           Async        Async       Async     Async    Async
      RPV Client  ax     Writes          KB Writes    Writes      KB Writes Writes   KB Writes
      ----------------------------------------------------------------------------------------
      hdisk9       A           0                0         0             0       0            0
      hdisk8       A     2061696        1018176796       21         10240       0            0

      You can use the rpvstat -n command to check the status and usage of network that connects the sites. You can use the rpvstat -A command to check the status of the asynchronous I/O operation. You can use the rpvstat -C command to check statistics of the cache logical volume.