Enable the partition lifecycle functionality

In order to put in place a partition lifecycle, you should create directories and grant permissions to the Datastore Runtime Main database user.

Create the directories

Create the following directories on the database server:

  • Backup directory: Contains the backup files which consist of the unmounted partitions table.
  • Commitment directory: Contains the commitment files stating that the backup succeeded. The names of the committed files must be the same as the names of the backup files with the extension .cmt.
  • Log directory: Contains the log files of the maintenance process.
  • Restoration directory: Contains the backup files used to remount partitions.
  • Temporary directory: Used by the maintenance process to temporarily store the backup files.

Create and declare the directories on the Oracle database server

To create and declare the directories:

  1. Create the directories in the file system.
  2. Declare and give the rights in Oracle using the following SQL commands:
    • create or replace directory XXX_DIRECTORY as 'DIRECTORY_PATH'
    • XXX_DIRECTORY is the name given by the user to one of the directories.
    • DIRECTORY_PATH is the path to the directory created in the file system.
    • grant READ, WRITE on directory XXX_DIRECTORY to MAIN_USER
    • MAIN_USER is the Datastore Runtime Main database user.

Create the directories on the MS SQL Server database server

  1. Create the directories in the file system and grant a modify permission for Proxy User (used by xp_cmdshell) and Users (used by OLE Automation File Management).
  2. Grant permissions to procedure xp_cmdshell
    • use master
    • create user MAIN_USER for login MAIN_LOGIN with default_schema=MAIN_SCHEMA
    • grant execute on xp_cmdshell to MAIN_USER
    • create credential ##xp_cmdshell_proxy_account## WITH IDENTITY = ‘DOMAIN\USER’, secret = ‘PASSWORD
    • MAIN_USER is the Datastore Runtime Main database user.
    • MAIN_LOGIN is the Datastore Runtime Main database login.
    • MAIN_SCHEMA is the Datastore Runtime Main database schema.
    • DOMAIN is the domain that owns the database.
    • USER is the operating system user that owns the database server.
  3. Grant permissions to sp_OACreate, sp_OAMethod,and sp_OADestroy
    • use master
    • grant execute on sp_OACreate to MAIN_USER
    • grant execute on sp_OAMethod to MAIN_USER
    • grant execute on sp_OADestroy to MAIN_USER
    • MAIN_USER is the Datastore Runtime Main database user.

Define settings in Administration

Settings values vary depending on the database used. With Oracle, the settings must have the value of the Oracle folder names, for example, BACKUP. With MS SQL Server, the settings must have the value of the database server directory path, for example, c:\Datastore\backup.

Define the following parameters in Administration.

  • Backup directory
  • Commitment directory
  • Log directory
  • Restoration directory
  • Temporary directory

Validate the parameters using the command dstools setting validate.

Related Links