You can extend storage capacity of encrypted non-High Availability (HA) systems by using
Logical Volume Manager (LVM) procedure.
Before you begin
Warning:
- Changing LVM configuration on a QRadar system might result in
data loss and data corruption. Always take a full back up of the system before you start LVM
procedure.
- The LVM procedures only support LVM expansion for systems with logical volume level encryption.
Do not perform these procedures on systems with partition or disk level encryption.
- Identifying encryption level
- The following command helps to identify the encryption level on the system for the
/store logical
volume:
xfs_info /store | grep meta-data | sed "s/meta-data=//" | cut -d " " -f1
Logical
volume encryption gives an output similar to the
following:/dev/mapper/luks-86ceb52c-d656-42f3-b2a3-6157a4ffa7cd
Partition or
disk level encryption givez an output similar to the
following:/dev/mapper/rhel-store
Procedure
The following procedures are for non-High Availability (HA) systems with logical volume level
encryption.
- Add a hard disk to the non-HA system and find the hard disk name by entering the
following command:
For example, sdb
- Create a partition table on the new hard disk by entering the following command:
parted /dev/<HD name> mktable gpt
- Create a partition for the whole disk by entering the following command:
parted /dev/<HD Name> mkpart xfs 1.00Mib 100%
- Search for the name of the new partition by entering the following
command:
lsblk
Typically, the device name with the number 1 at the
end is the partition name.
For example, sdb1
- Create the physical volume (PV) for this hard disk by entering the following
command:
pvcreate /dev/<Partition name>
- To add the storage, locate the volume group (VG). For example, storerhel is the
VG for the /store and /transient directories. Locate VG by
entering the following command:
- Extend the VG to include the space from the new partition by entering the following
command:
vgextend <Volume Group Name> /dev/<Partition name>
Note: This step is only required for all-in-one consoles and console devices.
It is
recommended that all-in-one consoles and consoles devices have more storage on the transient and
store volume. The transient volume should occupy 20% of the available space and the store volume
should occupy 80% of the remaining space. This step is not required for any other type of
appliances.
Warning: If you are extending the transient logical volume, you must complete this step
before you extend the store logical volume.
Extend the transient logical volume by using 20% of the free space in the VG by entering the
following command:
lvextend -l +20%FREE /dev/<VG Name>/transient
- This step extends the amount of free space for the store logical volume. To use this
system in a high availability environment, enough space must be available for the Distributed
Replicated Block Device (DRBD) metadata in the logical volume. Hence, extend the space for store by
97% of the free space by entering the following command:
lvextend -l +97%FREE /dev/<VG Name>/store
- You can search for the path for the store file system. Generally, the path is
/dev/mapper/<VG name>-<LV Name>.
For example, the path for the store file system is
/dev/mapper/storerhel-store.
To find the file system name of the
/store directory, enter the following
command:
xfs_info /store | grep meta-data | sed "s/meta-data=//" | cut -d " " -f1
- Resize the LUKS (Linux® Unified Key Setup)
encrypted space to include the space from the store logical volume, the passphrase for the encrypted
volume needs to be entered:
cryptsetup resize /dev/mapper/luks-<LUKS UUID>
Note: If storage was extended on the transient volume, then resize the LUKS encrypted space on that
volume as well.
- Grow the file system to fill the free space on the store LV by entering the following
command:
xfs_growfs /dev/mapper/<VG Name>-<LV Name>
Note: If storage was extended on the transient volume, you must grow the file system on the
transient LV as well.
- The file system is expanded to fill the remaining free space in the LV. Type the
following command to extend the store LV by 100% of the remaining space in the VG to leave room for
the DRBD metadata:
lvextend -l +100%FREE /dev/<VG Name>/store
- Resize the LUKS encrypted space to include the space from the store logical volume by
entering the passphrase for the encrypted volume:
cryptsetup resize /dev/mapper/luks-<LUKS UUID>