How to Increase vIDM appliance disk space
search cancel

How to Increase vIDM appliance disk space

book

Article ID: 319356

calendar_today

Updated On:

Products

VMware Aria Suite

Issue/Introduction

This resource provides instructions on how to increase the disk size of all VMware Identity Manager (vIDM) nodes.

Symptoms:
After a series of upgrades, the VMware Identity Manager (vIDM) appliances may not have the correct disk size for the updated version.


Resolution

  • Important Note: Delete any existing snapshots before resizing the hard disk, as disk size cannot be changed with active snapshots. Take new snapshots only after extending the disk.

    1. Run the below command on the appliance to identify the disk and associate SCSI ID.
      df -h;lsscsi;lsblk

    2. What is generally observed is when the vIDM appliance has been updated several times, it still features the disk layout from the initial non-Photon installation:


    3. Within vCenter, Shut down the Identity Manager virtual machine.
    4. Right-click the Identity Manager virtual machine and click Edit Settings.
    5. Extend Hard disk 1 to 60GB and Hard disk 2 and 3 to 20GB (if Hard disk 4 is present, it can be ignored).
      • Please extend the disk based on the file system in question. it is not mandatory to extend all the hard disks.


        Note: Take a snapshot of the VM as the hard disk size has been extended.
    6. Putty into the node as "root" and run the below command to rescan for the disk changes:
      echo 1 > /sys/class/block/sda/device/rescan
      echo 1 > /sys/class/block/sdb/device/rescan
      echo 1 > /sys/class/block/sdc/device/rescan
    7. Verify with fdisk -l

     

    Click the appropriate hyperlink below based on whether you are extending Root, SDB, or SDC.

    To Extend Root Partition:

    To Extend Data Partition - SDB:

    To Extend Data Partition - SDC:

    Extend the root partition by following steps below:

    1. Invoke partitioning tool (menu-driven interface) by running the below command.

    # cfdisk /dev/sda

    Note: This step is applicable only for the root partition:

    2. Using arrow keys select /dev/sda4

    3. Using tab key Or shift tab select [ Resize ] then enter
    4. Enter the free size available

    • For Example we selected 2M in the screenshot below:

    5. Using tab key select [ Write ]

    6. type "yes"

    7. Press tab to [ Quit ]

    8. Next, you must resize the file system with "resize2fs" to use the new space:

    [before resize2fs]
    # df -h | grep "sda4"
    /dev/sda4 8.8G 3.9G 4.5G 47% /
    
    [run resize2fs]
    # resize2fs /dev/sda4
    
    [after resize2fs]
    # df -h | grep "sda4"
    /dev/sda4 12G 3.9G 7.3G 35% /

    9. Run 'df -h' command to verify the allocated space.

     

    To resize the two data partitions which are LVMs and the steps are different here versus root partition:

    Extend the sdb data partition:

    1. Use "pvresize" to let LVM know that the physical disk size has changed:

    [before pvresize]
    # pvdisplay /dev/sdb
      --- Physical volume ---
      PV Name               /dev/sdb
      VG Name               db_vg
      PV Size               10.00 GiB / not usable 4.00 MiB
      Allocatable           yes (but full)
      PE Size               4.00 MiB
      Total PE              2559
      Free PE               0
      Allocated PE          2559
      PV UUID               xxxxxx-xxxx-xxxx-xxxx-xxxx-xxxx-xxxxxx
    
    [run pvresize]
    # pvresize /dev/sdb
    
    [after pvresize]
    # pvdisplay /dev/sdb
      --- Physical volume ---
      PV Name               /dev/sdb
      VG Name               db_vg
      PV Size               <20.00 GiB / not usable 0
      Allocatable           yes
      PE Size               4.00 MiB
      Total PE              5119
      Free PE               2560
      Allocated PE          2559
      PV UUID               xxxxxx-xxxx-xxxx-xxxx-xxxx-xxxx-xxxxxx

     

    2. Extend the logical volumes with "lvextend" to use the new space:
    [before lvextend]
    # lvdisplay /dev/db_vg/db
      --- Logical volume ---
      LV Path                /dev/db_vg/db
      LV Name                db
      VG Name                db_vg
      LV UUID                xxxxxx-xxxx-xxxx-xxxx-xxxx-xxxx-xxxxxx
      LV Write Access        read/write
      LV Creation host, time sc-xxx-xxx-xxx, 2019-09-12 15:55:23 +0000
      LV Status              available
      # open                 1
      LV Size                <10.00 GiB
      Current LE             2559
      Segments               1
      Allocation             inherit
      Read ahead sectors     auto
      - currently set to     256
      Block device           254:0
    
    [run lvextend]
    # lvextend -l +100%FREE /dev/db_vg/db
    
    [after lvextend]
    # lvdisplay /dev/db_vg/db
      --- Logical volume ---
      LV Path                /dev/db_vg/db
      LV Name                db
      VG Name                db_vg
      LV UUID                xxxxxx-xxxx-xxxx-xxxx-xxxx-xxxx-xxxxxx
      LV Write Access        read/write
      LV Creation host, time sc-xxx-xxx-xxx, 2019-09-12 15:55:23 +0000
      LV Status              available
      # open                 1
      LV Size                <20.00 GiB
      Current LE             5119
      Segments               1
      Allocation             inherit
      Read ahead sectors     auto
      - currently set to     256
      Block device           254:0

     

    3. Finally, use "resize2fs" to extend the file system on the two LVs:
    [before resize2fs]
    # df -h | grep "mapper"
    /dev/mapper/db_vg-db           9.8G 1014M  8.3G  11% /db
    
    [run resize2fs]
    # resize2fs /dev/db_vg/db
    
    [after resize2fs]
    # df -h | grep "mapper"
    /dev/mapper/db_vg-db            20G 1019M   18G   6% /db

    4. Run 'df -h' command to verify the allocated space.

     
    Extend the sdc Data Partition:

    1. Use "pvresize" to let LVM know that the physical disk size has changed:
    [before pvresize]
    # pvdisplay /dev/sdc
      --- Physical volume ---
      PV Name               /dev/sdc
      VG Name               tomcat_vg
      PV Size               10.00 GiB / not usable 4.00 MiB
      Allocatable           yes (but full)
      PE Size               4.00 MiB
      Total PE              2559
      Free PE               0
      Allocated PE          2559
      PV UUID               xxxxxxx-xxxx-xxxx-xxxx-xxxx-xxxx-xxxxxx
    
    [run pvresize]
    # pvresize /dev/sdc
    
    [after pvresize]
    # pvdisplay /dev/sdc
      --- Physical volume ---
      PV Name               /dev/sdc
      VG Name               tomcat_vg
      PV Size               <20.00 GiB / not usable 0
      Allocatable           yes
      PE Size               4.00 MiB
      Total PE              5119
      Free PE               2560
      Allocated PE          2559
      PV UUID               xxxxxx-xxxx-xxxx-xxxx-xxxx-xxxx-xxxxxx

     

    2. Extend the logical volumes with "lvextend" to use the new space:
    [before lvextend]
    # lvdisplay /dev/tomcat_vg/horizon
      --- Logical volume ---
      LV Path                /dev/tomcat_vg/horizon
      LV Name                horizon
      VG Name                tomcat_vg
      LV UUID                xxxxxx-xxxx-xxxx-xxxx-xxxx-xxxx-xxxxxx
      LV Write Access        read/write
      LV Creation host, time sc-xxx-xxx-xxx, 2019-09-12 15:55:24 +0000
      LV Status              available
      # open                 1
      LV Size                <10.00 GiB
      Current LE             2559
      Segments               1
      Allocation             inherit
      Read ahead sectors     auto
      - currently set to     256
      Block device           254:1
    
    [run lvextend]
    # lvextend -l +100%FREE /dev/tomcat_vg/horizon
    
    [after lvextend]
    # lvdisplay /dev/tomcat_vg/horizon
    
      --- Logical volume ---
      LV Path                /dev/tomcat_vg/horizon
      LV Name                horizon
      VG Name                tomcat_vg
      LV UUID                xxxxxx-xxxx-xxxx-xxxx-xxxx-xxxx-xxxxxx
      LV Write Access        read/write
      LV Creation host, time sc-xxx-xxx-xxx, 2019-09-12 15:55:24 +0000
      LV Status              available
      # open                 1
      LV Size                <20.00 GiB
      Current LE             5119
      Segments               1
      Allocation             inherit
      Read ahead sectors     auto
      - currently set to     256
      Block device           254:1

     

    3. Finally, use "resize2fs" to extend the file system on the two LVs:
    [before resize2fs]
    # df -h | grep "mapper"
    /dev/mapper/tomcat_vg-horizon  9.8G  7.1G  2.2G  78% /opt/vmware/horizon
    
    [run resize2fs]
    # resize2fs /dev/tomcat_vg/horizon
    
    [after resize2fs]
    # df -h | grep "mapper"
    /dev/mapper/tomcat_vg-horizon   20G  7.2G   12G  39% /opt/vmware/horizon

    4. Run 'df -h' command to verify the allocated space.

     

Additional Information