Before you run Offline Cleanup, review the following preparatory tasks and perform the tasks that are necessary for your environment:
To use the Offline Cleanup utility on Red Hat Linux, you must have certain 32-bit library files installed.
GRANT CREATE JOB TO <bsa schema user>
GRANT CREATE EXTERNAL JOB TO <bsa schema user>
GRANT EXECUTE ON DBMS_SCHEDULER TO <bsa schema user>
EXEC master..sp_addsrvrolemember @loginame = <bsa db user>, @rolename = 'sysadmin'
For an Oracle database, follow these steps:
Prior to running the cleanup process, it is worthwhile to capture the current size of the database tables so that these sizes can be compared to the post-cleanup sizes. To capture database table sizes, run one of the provided scripts, depending on your database type — either Oracle or SqlServer.
Note
Because the Oracle script queries the USER_TABLES to determine the size and row counts, ensure that a table statistics run has completed prior to running the analysis script.
To evaluate the impact of the cleanup process on the BMC Server Automation job data that you have stored in your database, you can use the dbm_cli command line utility. Use the following information modes:
To evaluate how much data would be cleaned out with various retention times, run the following command:
./dbm_cli.nsh -eval
Note
You can, alternatively, access a similar report through the GUI — through the Settings panel of the Database Maintenance Wizard. See Running offline database cleanup.
To determine what jobs and job runs would be affected by various retention times, run a command similar to the following example command:
./dbm_cli.nsh -impact Snapshot=30
This command is useful for determining whether the retention value passed during offline cleanup would remove any job runs that might need to be kept, as well as to see which specific jobs would be affected by the cleanup.