Extending the Directory Database

If the size of the database is approaching in one or more directory logical devices the initially foreseen size limit, or more attribute types must be indexed than predefined, then the directory database must be resized as follows:

  • Calculate, with the above described method, the new needed logical device size(s)

  • Stop the DirX Directory service.

  • Perform a backup of the database via:
    dirxbackup -S -v backup_file_name

  • Enlarge the respective concerned logical device(s) (for example replace the disk with a larger one or add another one or a partition and create a corresponding larger logical one by means of the operating system features)

  • Create a new profile with:
    dbamconfig -c -P new_profile_name -D … (using the new logical devices)

  • Perform again the basic initialization with the new profile through:
    dbamboot -P new_profile name -a new_number_of_indexed_attributes

    It is important that even after the resizing that the cluster size remains the same as before. Now, when the new AVIDX size has been calculated as described above this should normally lead to the satisfaction of this requirement.
    It can in some cases however happen that a discrepancy is discovered. In this case the cluster size can be adjusted varying the new_number_of_indexed_attributes. Increasing it will reduce the cluster size and vice versa.
    If the adjustment can only be achieved through a reduction of the new_number_of_indexed_attributes below the real needed number of such attributes, then the AVIDX size is still too small and will have to be further enlarged. After that, the procedure can be resumed with the reconfiguration via dbamconfig as just described. (See also the information about the AVIDX device below for details.)
  • Restore the directory database with:
    dirxbackup -R -v backup_file_name

  • Delete the old profile with:
    dbamconfig -d -P profile_name

  • Start the DirX Directory service.

When increasing the DBAM devices the following rules apply:

  • Profile compatibilty:

    The new profile must be compatible with the old profile. That is:

    • You can only enlarge the device sizes.

    • You must specify the devices as you had specified them in the old profile, for example you cannot modify the combination of GENERAL, BITSTR, PSEUDO, and TREE devices.

    Perform the command
    dirxbackup –Ti [archive_name]
    to display the profile information of your backup.

  • REAL device:

    See the dbamconfig command reference page in the DirX Directory Administration Reference for the maximum REAL device size.

    If you are uncertain about the applied real object block size you can find it in the file schemaPID.txt where PID is the process id of the DSA process. The DSA process writes basic settings to this file at start-up time. It is located in the directory install_path/server/log.

    Here is an example how the real block size is written to this file:

    DBAM data:
    
    ...
    Real object block size :    1 KB

    In this example with a real block size of 1 KB you can increase the REAL device size to a maximum value of 512GB.

  • AVIDX device:

    The maximum size for increasing the AVIDX device depends on the applied AVI cluster size of the old database. dbamboot has calculated the appropriate cluster size when initializing the database. When you enlarge the AVIDX device size it must fit to the cluster size of the old profile.

    The following table lists the maximum values in relationship to the cluster size of the old database:

    Cluster Size

    Maximum Device Size

    8 MB

    26 GB

    32 MB

    102 GB

    128 MB

    409 GB

    Like the real block size you find the AVI cluster size in the file schemaPID.txt. (See information above for details.)

    Here is an example how the AVI cluster size is written to this file:

    DBAM data:
    
    Number of AVI types    :   20
    Number of AVI cluster  :  151
    AVI cluster size       :  128 MB
    Real object block size :    1 KB

    In this example with a AVI cluster size of 128 MB you can increase the AVIDX device size to a maximum valueof 409GB.

  • GENERAL, BITSTR, PSEUDO, TREE device:

    See the dbamconfig command reference page in the DirX Directory Administration Reference for maximum device sizes.

Example

The AVIDX device has a size of 1GB and all clusters are allocated. dbamdevinfo reports the following output for the AVIDX device:

Attribute index specific device info:
    Attr id  LDAP name         Index type  Size
    0        objectClass       INITIAL        0.031 MB (   1 cluster)
    3        cn                INITIAL      253.766 MB (  33 cluster)
    3        cn                FINAL        331.859 MB (  42 cluster)
    4        sn                INITIAL      206.891 MB (  26 cluster)
    4        sn                FINAL        168.000 MB (  21 cluster)
    13       o                 INITIAL        0.016 MB (   1 cluster)
    13       o                 FINAL          0.016 MB (   1 cluster)
    15       ou                INITIAL        0.016 MB (   1 cluster)
    15       ou                FINAL          0.016 MB (   1 cluster)

    Number of indices: 9      (maximum 80)
    Cluster usage:     100 %  (127 of 127)

To enlarge the AVIDX device perform the following steps :

  • Stop the DirX Directory service

  • Save the database with dirxbackup:
    dirxbackup -S -v ArchiveDB

  • Increase the AVIDX device for example to 6GB.

  • Create a new enlarged profile:
    dbamconfig -c -D D:\RawDevices\DB,REAL=16GB,AVIDX=6GB
    -T D:\RawDevices\Translog
    -Pprofile2

  • Initialize the new enlarged profile:
    dbamboot -Pprofile2

  • Restore the database with dirxbackup:
    dirxbackup -R ArchiveDB

  • Delete the profile:
    dbamconfig -d -Pprofile1

  • Start the DirX Directory service.

dbamdevinfo now reports the new free cluster:

Attribute index specific device info:
    Attr id  LDAP name         Index type  Size
    0        objectClass       INITIAL        0.031 MB (   1 cluster)
    3        cn                INITIAL      253.766 MB (  33 cluster)
    3        cn                FINAL        331.859 MB (  42 cluster)
    4        sn                INITIAL      206.891 MB (  26 cluster)
    4        sn                FINAL        168.000 MB (  21 cluster)
    13       o                 INITIAL        0.016 MB (   1 cluster)
    13       o                 FINAL          0.016 MB (   1 cluster)
    15       ou                INITIAL        0.016 MB (   1 cluster)
    15       ou                FINAL          0.016 MB (   1 cluster)

    Number of indices: 9        (maximum 80)
    Cluster usage:     16.56 %  (127 of 767)