Control-M Workload Archiving Configuration
Control-M Workload Archiving is a Control-M add-on that enables you to archive job data in a secure, central repository when jobs finish execution. The Workload Archiving Server archives Control-M/Server job logs, Agent job output, and a small amount of job metadata from Control-M/EM in a separate PostgreSQL or Oracle database for a defined period of time, based on the active Workload Archiving policy.
Workload Archiving policies determine the job data that is archived based on some of the following main criteria:
-
Data Type: Job logs or output.
-
Retention Period: The number of days, months, or years to archive the data.
-
System Type: Distributed systems or z/OS mainframes.
-
The Workload Archiving process receives Control-M/EM authorization data to apply Control-M/EM user authorization rules. You do not need to define additional authorizations, as described in User and Role Authorizations.
-
(z/OS only) To collect job output and logs, you must define the security user ARCUSER with the View LOG and View SYSOUT permissions.
-
(z/OS only) To enable the efficient performance of log archiving, you must activate and ensure periodic updates of the IOA Log Index component, as described in IOA Log Index.
The following procedures describe how to start up and configure Workload Archiving settings:
The following utilities enable you to configure Workload Archiving:
-
arc_database_menu: Start, stop, backup, restore, and perform other Workload Archiving database tasks.
-
Workload Archiving Command Line Utilities: Start, stop, check the Workload Archiving server status, and perform other tasks.
Starting Up the Workload Archiving Server
This procedure describes how to start up the Workload Archiving Server from the CCM.
Begin
-
From the Components Tree in the left pane, right-click the Workload Archiving Server component, select Desired State, and then select Up.
The Workload Archiving Server starts up.
Shutting Down the Workload Archiving Server
This procedure describes how to shut down the Workload Archiving Server from the CCM.
Begin
-
From the Components Tree in the left pane, right-click the Workload Archiving Server component, select Desired State, and then select Down.
The Workload Archiving Server shuts down.
Deleting Data from the Workload Archiving Server
This procedure describes how to delete data—including jobs, output, and logs—from the Workload Archiving server. You can delete data that belongs to a specific rule or to data that matches specific command criteria.
Begin
-
Type one of the following commands:
-
Rule Name: arc_cleanup -user <user> -password <password> -rule <rule_name>
-
Data Attributes: arc_cleanup -user <user> -password <password> -job_name <job_name> -job_name_exceptions <job_name_exceptions> -ctm <Control-M/Server name> -ctm_exceptions <Control-M/Server name exceptions> -job_state <OK|NOTOK> -app <Application name> -app_exceptions <appNameExceptions> -subapp <Sub-application_name> -subapp_exceptions <Sub-application_exceptions> -folder <folder_name> -folder_exceptions <folder_name_exceptions> -lib <library> -lib_exceptions <library_exceptions>
arc_cleanup Parameters
The following table describes the mandatory arc_cleanup parameters.
Parameter
Description
-user
Defines the username.
You can use * and ? wildcards, as described in Pattern-Matching Strings.
-password
Defines the user password.
Rules:
-
Wildcards: You can use * and ? wildcards, as described in Pattern-Matching Strings.
-
! Characters: Passwords that contain ! characters must be enveloped in " and a \ must precede the !.
The following command uses an ! character in its password and deletes all archived jobs that contain the string AA, except for job names that begin with the letter B:
arc_cleanup –user <user> -password "Passw\!rd" –job_name "*AA*" –job_name_exceptions "B*"
-
Defining a Workload Archiving Policy
This procedure describes how to define a Workload Archiving policy that enables you to determine which data to archive and how long to store it in the Workload Archiving database.
Begin
-
From the
icon, select Configuration.The Configuration domain opens.
-
From the
drop-down list, select Workload Archiving.The Workload Archiving tab appears.
-
Click Add Rule.
The Add Archive Policy Rule dialog box appears.
-
In each field, type or select the required value, as described in Workload Archiving Policy Rule Parameters.
-
Click Add.
The Workload Archiving policy rule appears in the table.
Workload Archiving Policy Rule Parameters
The following table describes the Workload Archiving policy rule parameters.
|
Attribute |
Description |
|---|---|
|
Activate Rule |
Determines whether to activate a Workload Archiving policy rule. |
|
Name |
Defines the Workload Archiving policy name. |
|
Description |
Defines a free-text description of the Workload Archiving policy. |
|
Archive Data |
Determines which of the following data to archive:
|
|
Retention Period |
Determines the number of days, months, or years to archive the data defined in Archive Data. |
|
Platform |
Determines which of the following platforms archive the data:
|
|
Job Type |
Determines the job type of the jobs to archive (for example, OS jobs). This attribute is not relevant for z/OS. |
|
Job Status |
Determines whether to archive jobs with the following status:
|
|
Output Limit |
Determines the maximum amount of storage on the Workload Archiving Server to reserve for the job output. Range:
|
|
Trim Output |
Discards all or part of the job output file if it exceeds the amount defined in Output Limit. Valid Values:
|
|
Control-M/Server |
Filters the jobs on the Control-M/Server that you define. You can use * and ? wildcards, as described in Pattern-Matching Strings. |
|
Job Name |
Filters the jobs to be archived. You can use * and ? wildcards, as described in Pattern-Matching Strings. |
|
Application |
Filters the jobs in the Applications that you define. You can use * and ? wildcards, as described in Pattern-Matching Strings. |
|
Sub-application |
Filters the jobs in the Sub-applications that you define. You can use * and ? wildcards, as described in Pattern-Matching Strings. |
|
Folder Name |
Filters the jobs in the folders that you define. The folders are defined in the following format: <SMART_Folder_Name>/<Sub-folder_Name> You can use * and ? wildcards, as described in Pattern-Matching Strings. The following SMART folders and sub-folders are defined in a Workspace:
The Folder parameter is defined as follows:
|
|
Folder Library |
(z/OS only) Filters the folder libraries for z/OS. You can use * and ? wildcards, as described in Pattern-Matching Strings. |
Configuring the Workload Archiving Cyclic Log Collection
This procedure describes how to configure how often Workload Archiving archives cyclic job logs and outputs. This can reduce the load on resources, such as CPU usage and disk space.
Begin
-
From the Control-M/EM host, navigate to the following directory:
<Control-M/EM_Home>\archive\config
-
Open the SystemParameters.xml file and locate the cyclic.log.collection.interval.minutes system parameter.
-
Change the parameter value to reflect how often, in minutes, Workload Archiving archive cyclic job logs and outputs.
If you enter a value of 0, Workload Archiving archives a cyclic job log and output after every job execution.
Configuring Retention Parameters to Prevent Loss of Archive Data
This procedure describes how to check and adjust retention parameters, which enables you to prevent data loss when the Workload Archiving server is down and cannot archive job data. You must ensure that data is retained in the Control-M components over the period of time that begins when the Workload Archiving server goes down and ends after Workload Archiving completes retrieval of the stored job data on the components when the server is back up.
Before You Begin
-
Set aside additional free database space on Control-M/EM and Control-M/Server and additional disk space on each Agent to accommodate the extra space required for storing more days of job logs and output files.
Begin
-
Do the following to update the retention parameters for Control-M/Server via the ctmsys utility:
-
Run the ctmsys utility, as described in Running the ctmsys Utility.
-
From the Main Menu, choose option 2, System Parameters.
-
Type n to display the second page of parameters.
-
Update the following parameters with larger values:
-
6 - Maximum Days Retained by Control-M Log
-
7 - Maximum Days to Retain Output Files
-
-
Save your changes and exit the utility.
-
-
To create a retention period that is longer than the default of 30 days, do the following:
-
Update the GENERAL_CLEANUP_INTERVAL parameter on each of your Agents, as described in Configuring Agent System Parameters and Diagnostics Parameters.
-
Update the following Control-M/EM system parameters, as described in Configuring Control-M/EM System Parameters:
-
ArchiveRetentionPeriod: See Control-M Workload Archiving Parameters.
-
RunTimeHistoryDays: See Control-M Workload Archiving Parameters.
-
-
-
Do the following to verify that the Control-M/Server retention parameters take effect on all Agents:
-
Open the CONFIG.dat file in the following directory and delete the SYSKEEPDAYS parameter if it is there:
-
UNIX/Linux: <Agent_home>/data/
-
Windows: <Agent_home>\Default\DATA
-
-
From the CCM, right-click each Agent and select Properties.
The Control-M/Agent Properties dialog box appears.
-
From the Output tab, verify that the Days to retain OUTPUT files drop-down list is set to Default.
-
Open the config.dat file in the following directory:
- UNIX/Linux: <Control-M/Server_home>/ctm_server/data
-
Windows: <Control-M/Server_home>\ctm_server\data
-
Add or update the following line:
AGENTS_CLEANUP_IN_NEWDAY Y
-
Restart the Control-M/Server.
-
-
Update the following retention parameters in $EM_HOME/archive/config/SystemParameters.xml, on the Workload Archiving server, with the same values that you used in Step 1:
-
override.num.days.log.keep.in.server
-
override.num.days.output.keep.in.server
-
-
Recycle the Workload Archiving server.
The retention parameters are reconfigured.
Workload Archiving Command Line Utilities
The following table describes the Workload Archiving command line utilities.
|
Utility |
Description |
|---|---|
|
arc_start_server |
Starts up the Workload Archiving server. |
|
arc_stop_server |
Shuts down the Workload Archiving server. |
|
arc_server_state |
Checks the status of the Workload Archiving server. |
|
arc_kill_server |
Terminates Workload Archiving server processes if they do not stop regularly. |
|
arc_sql |
Starts an SQL prompt in the Workload Archiving database. |
|
arc_data_collector |
Creates a package of OS and Workload Archiving logs and configuration for review by BMC Support. |
|
arc_recollect_jobs |
Attempts to recollect the job output or log after the Workload Archiving server fails to collect and exceeds the retry threshold. To avoid resource overload on the Workload Archiving server, apply accurate search criteria when you run this script. |
