# Configuring Database Cleanup

This functionality cleans the loaded data in the SQL database. Use this to free up space when the database has grown too large in volume.

The daily processing of Analysis Server data includes the Database Cleanup processing. The configuration will reflect on the next execution, but for immediate testing, run the RunEtl command and see the effect of the configuration.

# Configuring openit.cfg for Database Cleanup

  1. In a Core Server installation, open openit.cfg in the Configuration directory which is by default located in C:\Program Files\OpeniT\Core\Configuration.

  2. Locate the following directives and set its values:

    • DBCLEAN_ENABLE - triggers the Core Server to do database cleanup.

        DBCLEAN_ENABLE y
    • DBCLEAN_INTERVAL - the day when to perform the cleanup. The default value is Sunday.

        DBCLEAN_INTERVAL Sunday
  3. Save the changes.

# Database Cleanup Settings for Analysis Server

This configuration file includes parameters that determine how the cleanup process is executed and which data type is targeted for deletion.

  1. Open database_cleanup.conf in the Configuration directory of Core Server, located by default in C:\Program Files\OpeniT\Core\Configuration\.

    Notice that it contains instructions on how to edit the file. If configuring Analysis Server, follow the instructions specified for Analysis Server; and if configuring Core Server, follow the instructions specified for Core Server.

  2. Specify settings by adding entries with the following syntax:

    SDW:AA:B:CCC

    Where:

    Key Description Acceptable Value
    SDW Signifies that the entry is for Analysis Server or SQL Data Warehouse. static
    A The number representing the Open iT data type. e.g., 93, 102
    "*" (all data)
    B The level of data to clean up from the database.
    Specifying a high data level means cleaning all the data below it. Specifying Y will clean all the data in M and W.
    Y - Year
    M - Month
    W - Week
    C The age of the data before it is deleted. This parameter is exclusive; it does not include the current Year, Month or Week of execution. Setting 4 in week 16 will delete all data up to week 11. e.g., 5, 4, 7
    Database Cleanup Settings for Analysis Server

    Example 1

    The following configuration deletes StorageAnalyzer data types, Filesystems and Filespace, that are older than three years.

    SDW:24:Y:3
    SDW:29:Y:3

    Example 2

    The configuration below deletes all data types in the Analysis Server that are older than five years.

    SDW:*:Y:5
  3. Save the changes.

# Configuration Examples

Use the following examples as guide for configuring database cleanup.

Entry Description
SDW:75:Y:2 Delete all License Logfile Events (DT 75) data that is older that 2 years.
SDW:102:M:13
SDW:90:M:13
Delete all Olap Total Use (DT 102) and Licenseevents Individual Usage (DT 90) data that is older than 13 months.
SDW:*:M:18 Delete all data that is older than 18 months.
SDW:*:Y:1
SDW:75:M:18
Delete all data that is older than 1 year but keep License Logfile Events (DT 75) data that is older than 18 months.
Database Cleanup Configuration Examples

The file treats the '*' (all) as the general level and the data types is in the higher level. The data types with specific entry will be excluded in processing the for the entry for '*' (all) level. This means that the lines can be sorted any way.

We value your feedback!

Please take a few minutes to complete our survey and share your thoughts on your recent experience with our documentation.

Take survey

Close