# Genesys Quality Management Suite 8.1.520 : Storage Management

This section describes how to re-size your storage. In most of the cases administrators re-evaluate their storage needs after going into production. At some point most administrators need to extend their storage capacity. The examples below provide some general steps related to Call Recording settings that affect this task.

## Example of increasing /opt Partition

Before you start increasing your /opt partition, stop all processes that are accessing anything on the partition. See some of the processes that may need to be stopped are:

    service callrec stop
    service postgresql stop
    service nagios stop
    service postfix stop

1. If there are any processes left that are blocking you from umounting /opt, you can review them like this:

       lsof | head -n1 ; lsof | grep opt

2. Take a note of the LV name that you want to extend. For example, it may be called something like /dev/mapper/volgrp01-optlv

       df -h | grep -i opt
       /dev/mapper/volgrp01-optlv                 26G  3.6G   21G  15% /opt

3. Once finished with all dependencies, umount /opt.

       umount /opt

4. Let's assume your new disk that you would like to add was detected by the Linux system as sdb. Once system detected new harddisk, you need to create partition on it.

       fdisk /dev/sdb

5. To create partition, first press "n" for new, then type "p" for partition, then "1" for first partition and then just hit enter several times, until you get back into the fdisk prompt. Save the changes using the "w" key. Make sure you do this operation on correct disk. Doing it on wrong hard disk may result in complete dataloss.
   Now we need to find out which VG is this LV part of. To find that out, you can use for example following, where the argument is the LV name that you took a note of in previous steps

       lvdisplay /dev/mapper/volgrp01-optlv | grep -i 'VG Name'

6. Result of previous command is going to be VG name, likely something like volgrp01. Now we need make LVM aware that new disk is going to be used. /dev/sdb1 should be replaced by any harddisk that you wish to add into the LVM.

       pvcreate /dev/sdb1

   Now we assign this disk into the proper VG that we found out in previous steps

       vgextend volgrp01 /dev/sdb1

7. And finally we are ready to extend the actual LV. To do that, you can use for example following, which will extend optlv as much as its available (to 100% capacity).

       lvextend -l +100%FREE /dev/volgrp01/optlv

8. As a last step, you need to make this change apparent to the filesystem as well.

       resize2fs /dev/mapper/volgrp01-optlv

9. Mount opt partition again.

       mount /opt

/opt partition is now increased to maximum available size.

Please note that while increasing filesystem can be done on-line (without unmounting the filesystem or stopping Callrec), unless you are experienced Linux administrator, its generally safer to do it off-line. However, doing it on-line should give you no troubles also.