Configuring local volumes for an installation of IBM Cloud Pak for AIOps on Linux

Learn about configuring logical storage volumes for an installation of IBM Cloud Pak for AIOps on Linux.

Overview

Each control plane node in your Linux® cluster must have two separate disks in addition to the boot disk. One disk is dedicated to persistent storage for IBM Cloud Pak® for AIOps, while the other is reserved for platform storage. Similarly, each worker node in the cluster must have a dedicated disk for IBM Cloud Pak for AIOps's persistent storage. This protects and isolates application and platform data from the rest of the node, and provides capacity limiting that protects the root volume from being filled by application data.

IBM Cloud Pak for AIOps deployments on Linux require 3000 GB of persistent local storage across all of the nodes in your Linux cluster. Each node must have a minimum of 250GB.

The following procedure is suggested to create separate logical volumes for IBM Cloud Pak for AIOps's application storage, and for platform storage. The procedure is for logical volume management, and some steps may be different for your chosen storage management solution.

Warning: Although it is possible to configure a separate partition and volume on an existing disk, this is not recommended. For more information, see Multiple partitions on a disk in the Red Hat® Enterprise Linux® documentation.

Procedure

  1. Configure logical volumes on the control plane nodes.

    Run the following steps on each of your control plane nodes.

    1. Identify two blank disks that can be used for IBM Cloud Pak for AIOps's application storage and for platform storage.

      fdisk -l
      

      Example output where /dev/vdb and /dev/vdc can be used:

      $ fdisk -l
      
      Device     Boot   Start       End   Sectors  Size Id Type
      /dev/vda1  *       2048   2099199   2097152    1G 83 Linux
      /dev/vda2       2099200 524287999 522188800  249G 8e Linux LVM
      
      Disk /dev/vdb: 200 GiB, 214748364800 bytes, 419430400 sectors
      Units: sectors of 1 * 512 = 512 bytes
      Sector size (logical/physical): 512 bytes / 512 bytes
      I/O size (minimum/optimal): 512 bytes / 512 bytes
        
      Disk /dev/vdc: 200 GiB, 214748364800 bytes, 419430400 sectors
      Units: sectors of 1 * 512 = 512 bytes
      Sector size (logical/physical): 512 bytes / 512 bytes
      I/O size (minimum/optimal): 512 bytes / 512 bytes
      

    2. Export environment variables.

      export APP_DRIVE_NAMES=(
        <app_drive_name> 
      )
      export PLATFORM_DRIVE_NAMES=(
        <plat_drive_name>
      )
      
      export APP_STORAGE_PATH="/var/lib/aiops/storage"
      export PLATFORM_STORAGE_PATH="/var/lib/aiops/platform"
      

      Where

      • <app_drive_name> is a blank disk that you identified in step 1. For example: "/dev/vdb"
      • <plat_drive_name> is a different blank disk that you identified in step 1. For example: "/dev/vdc"

      Note: You can set different values for $APP_STORAGE_PATH and $PLATFORM_STORAGE_PATH if you want. If you do, then note the values that you use and ensure that you specify these values when you install IBM Cloud Pak for AIOps. You must use the same value for $APP_STORAGE_PATH for all control plane and worker nodes, and you must use the same value for $PLATFORM_STORAGE_PATH for all control plane nodes.

    3. Run the following commands to configure the drives and volumes:

      # Create physical volumes
      pvcreate "${APP_DRIVE_NAMES[@]}"
      pvcreate "${PLATFORM_DRIVE_NAMES[@]}"
      
      # Create volume groups
      vgcreate aiops "${APP_DRIVE_NAMES[@]}"
      vgcreate aiopspl "${PLATFORM_DRIVE_NAMES[@]}"
      
      # Create logical volumes on the volume groups
      lvcreate aiops -n aiops -l 100%FREE
      lvcreate aiopspl -n aiopspl -l 100%FREE
      
      # Format the new logical volumes
      export APP_DMPATH=$(lvs --noheadings -o dmpath aiops | sed -e 's/^[[:space:]]*//')
      export PLATFORM_DMPATH=$(lvs --noheading -o dmpath aiopspl | sed -e 's/^[[:space:]]*//')
      mkfs.xfs -L aiops "${APP_DMPATH}"
      mkfs.xfs -L aiopspl "${PLATFORM_DMPATH}"
      
      # Create filesystem directories
      mkdir -p "${APP_STORAGE_PATH}"
      mkdir -p "${PLATFORM_STORAGE_PATH}"
      
      # Add the new filesystem directories to `/etc/fstab`
      echo "${APP_DMPATH}  ${APP_STORAGE_PATH}     xfs    defaults        0 0" >> /etc/fstab
      echo "${PLATFORM_DMPATH}  ${PLATFORM_STORAGE_PATH}     xfs    defaults        0 0" >> /etc/fstab
      
      # Mount the filesystems into the directories
      systemctl daemon-reload
      mount "${APP_STORAGE_PATH}"
      mount "${PLATFORM_STORAGE_PATH}"
      
    4. Verify that the mount points are correctly configured.

      Run the following command to verify that you have two new mount points called aiops and aiopspl for the storage locations that you specified, on the disks that you identified.

      lsblk --output NAME,KNAME,TYPE,MAJ:MIN,FSTYPE,SIZE,RA,MOUNTPOINT,LABEL
      

      Example output where vdb and vdc are now configured as the mount points for aiops and aiopspl:

      $ lsblk --output NAME,KNAME,TYPE,MAJ:MIN,FSTYPE,SIZE,RA,MOUNTPOINT,LABEL
      NAME              KNAME TYPE MAJ:MIN FSTYPE       SIZE   RA MOUNTPOINT             LABEL
      vda               vda   disk 252:0                250G 4096
      ├─vda1            vda1  part 252:1   xfs            1G 4096 /boot
      └─vda2            vda2  part 252:2   LVM2_member  249G 4096
        ├─rhel-root     dm-0  lvm  253:0   xfs          233G 4096 /
        └─rhel-swap     dm-1  lvm  253:1   swap          16G 4096 [SWAP]
      vdb               vdb   disk 252:16  LVM2_member  200G 4096
      └─aiops-aiops     dm-2  lvm  253:2   xfs          200G 4096 /var/lib/aiops/storage aiops
      vdc               vdc   disk 252:16  LVM2_member  200G 4096
      └─aiopspl-aiopspl dm-2  lvm  253:2   xfs          200G 4096 /var/lib/aiops/platform aiopspl
      

  2. Configure logical volumes on the worker nodes.

    Run the following steps on each of your worker nodes.

    1. Identify a blank disk that can be used for IBM Cloud Pak for AIOps's application storage.

      fdisk -l
      

      Example output where /dev/vdb can be used:

      $ fdisk -l
      
      Device     Boot   Start       End   Sectors  Size Id Type
      /dev/vda1  *       2048   2099199   2097152    1G 83 Linux
      /dev/vda2       2099200 524287999 522188800  249G 8e Linux LVM
      
      Disk /dev/vdb: 200 GiB, 214748364800 bytes, 419430400 sectors
      Units: sectors of 1 * 512 = 512 bytes
      Sector size (logical/physical): 512 bytes / 512 bytes
      I/O size (minimum/optimal): 512 bytes / 512 bytes
      

    2. Export environment variables.

      export APP_DRIVE_NAMES=(
        <app_drive_name> 
      )
      
      export APP_STORAGE_PATH="/var/lib/aiops/storage"
      

      Where <app_drive_name> is a blank disk that you identified in step 1. For example: "/dev/vdb"

      Note: You can set a different value for $APP_STORAGE_PATH if you want. If you do, then note the value that you use and ensure that you specify this when you install IBM Cloud Pak for AIOps. You must use the same value for $APP_STORAGE_PATH for all control plane and worker nodes.

    3. Run the following commands to configure the drives and volumes:

      # Create physical volumes
      pvcreate "${APP_DRIVE_NAMES[@]}"
      
      # Create volume groups
      vgcreate aiops "${APP_DRIVE_NAMES[@]}"
      
      # Create a logical volumes
      lvcreate aiops -n aiops -l 100%FREE
      
      # Format the new logical volume
      export APP_DMPATH=$(lvs --noheadings -o dmpath aiops | sed -e 's/^[[:space:]]*//')
      mkfs.xfs -L aiops "${APP_DMPATH}"
      
      # Create filesystem directory
      mkdir -p "${APP_STORAGE_PATH}"
      
      # Add the new filesystem directory to `/etc/fstab`
      echo "${APP_DMPATH}  ${APP_STORAGE_PATH}     xfs    defaults        0 0" >> /etc/fstab
      
      # Mount the filesystem into the directory
      systemctl daemon-reload
      mount "${APP_STORAGE_PATH}"
      
    4. Verify that the mount point is correctly configured.

      Run the following command to verify that you have a new mount point called aiops for the storage location that you specified on the disk that you identified.

      lsblk --output NAME,KNAME,TYPE,MAJ:MIN,FSTYPE,SIZE,RA,MOUNTPOINT,LABEL
      

      Example output where vdb is now configured as the mount points for aiops:

      $ lsblk --output NAME,KNAME,TYPE,MAJ:MIN,FSTYPE,SIZE,RA,MOUNTPOINT,LABEL
      NAME              KNAME TYPE MAJ:MIN FSTYPE       SIZE   RA MOUNTPOINT             LABEL
      vda               vda   disk 252:0                250G 4096
      ├─vda1            vda1  part 252:1   xfs            1G 4096 /boot
      └─vda2            vda2  part 252:2   LVM2_member  249G 4096
        ├─rhel-root     dm-0  lvm  253:0   xfs          233G 4096 /
        └─rhel-swap     dm-1  lvm  253:1   swap          16G 4096 [SWAP]
      vdb               vdb   disk 252:16  LVM2_member  200G 4096
      └─aiops-aiops     dm-2  lvm  253:2   xfs          200G 4096 /var/lib/aiops/storage aiops
      

Note: If the logical volume sizes need to be increased after installation, follow the instructions in Resizing storage (IBM Cloud Pak for AIOps on Linux).