Drive control

In order to reduce the risk of disk full errors, the platform divides the file system over several disks keeping areas liable to grow outside the main root filesystem. The areas with the highest growth such as logs and database storage are kept on their own private file systems.

Note

The database mount point is stored in a logical volume.

These disk mounts can be migrated onto new, larger disks and some other locations can optionally be moved onto their own disks. This is managed through the drives  command.

The current mounted filesystems and mount points can be displayed using drives list mounted and drives list mountpoints respectively.

A screen showing drives list mounted and drives list mountpoints:

platform@development:~$ drives list mountpoints
Used disks and mountpoints:
    sdc1 -  services:backups
    dm-0 -  mongodb:dbroot

Unused disks:
sde

Unused mountpoints:
    services:SWAPSPACE

Volume Groups
    voss - 25.0 GB free, 250.0 GB total
      Physical volumes:
        sdd1
      Logical volumes:
        dbroot/dm-0 - 225.0 GB

platform@development:~$ drives list mounted
Used disks and mountpoints:
    sdc1 -  services:backups
    dm-0 -  mongodb:dbroot
platform@development:~$

The mount points are as follows:

  • mongodb:dbroot is the volume used for database storage

  • services:backups is used for default backup storage

  • services:appdata is the main system volume used for application data in the users account

  • services:SWAPSPACE is the swap volume used by the system

Note

While the system is carrying out a backup, additional Unused disks, for example dm-1, dm-2, may show when the drives list command is run. These disks are used for snapshots and will not display once the backup is completed.

In order to add or extend an existing disk volume, follow the following steps:

  • Under VMware, add an additional disk volume to the VM

  • drives list displays any unused available volumes

  • A free mount point can be linked to a new disk using drives add <disk> <mountpoint>.

    Note

    The drive add command on a Generic NBI node (for Billing Data Extract) is not in use.

  • An existing used mountpoint (i.e. currently linked to a disk volume) can be linked to a new disk volume of greater size using drives reassign <disk> <mountpoint> <new disk size in GB>.

    The <new disk size in GB> specification means the volume need not be the size of the entire disk. However, a specified size must not be more than 90% of the disk size (or more than <disk size less 10GB> if the disk size is 100GB or smaller).

    Existing data on the current disk will be copied to the new disk volume, and once successful, the new disk volume will be linked.

For example, the following steps can be followed to add a 250GB hard disk to the system:

  1. Log into the VMware console and select Server.

  2. Right-click and select Edit settings.

  3. Click Add… and select Hard Disk.

  4. Step through the rest of the wizard and edit parameters - in this case 250GB, thick provisioned.

  5. Once done, log into system as the platform user.

  6. Carry out a disk listing with the command drives list.

  7. Reassign the disks with the command:

    • For the database mount point (mongodb:dbroot), a Volume Group must be reassigned:

      1. drives create_volume <volume_name> <new disk name>.

      2. Carry out a disk listing to check the Volume Group with the command drives list.

      3. drives reassign <volume_name> mongodb:dbroot <size in GB>. The <size in GB> specification means the volume need not be the size of the entire disk. However, a specified size must not be more than 90% of the disk size (or more than <disk size less 10GB> if the disk size is 100GB or smaller).

      4. Old volumes can be removed with:

        • drives remove_logical <volume_name> <logical_volume_name>

        • drives remove_volume <volume_name>

    • For other mount points, a disk must be reassigned: drives reassign <disk> <mountpoint>

  8. Start the application with app start.

  9. Verify the new reassignment with the command drives list.

Note

Volume Groups for database mount points reserve a 10% or 10GB space - whichever is the largest - which is used for and then released during database backups.

SAN alignment is implemented using the offset value in drives offset. This value can be changed if necessary; however the default should be sufficient for most SAN hardware.

For swap partitions, use drives checkswap to check their alignment. Use drives alignswap to fix a misaligned swap partition.