■ New Day procedure
A procedure, called the New Day procedure, is defined for each CONTROL-M/Server. Each day, at its
designated New Day time, each CONTROL-M/Server runs its New Day procedure. This procedure
automatically starts process and functions required at the start of a new day under CONTROL-M,
including daily cleanup and housekeeping, and the scheduling of current day’s production jobs.
At the beginning of the New Day procedure, the procedure calculates a new CONTROL-M working date,
and displays the message FORMATTING AJF in the CONTROL-M/EM Communication Status window for
the CONTROL-M.
The following is a list of some of the more important cleanup and housekeeping functions that the New
Day procedure automatically initiates. You can adjust or disabled many of them:
■ Partial cleanup of the CONTROL-M/Server log (based on system parameter Maximum Days Retained
By CONTROL-M Log)
■ Partial cleanup of job SYSOUT directories on agent computers (based on system parameter Maximum
Days to Retain Sysout Files)
■ selective cleanup of the Active Jobs file—jobs that have already executed and ended OK, and jobs
whose parameter Max Wait has been exceeded (and are not Held), are erased from the Active Jobs file
■ selective cleanup of prerequisite conditions—to prevent jobs from being triggered by prerequisite
conditions remaining from the previous year, prerequisite conditions are deleted if they are one year old
(prerequisite conditions whose month and day date reference is equal to tomorrow’s date— the new
CONTROL-M working date +1. For more information on prerequisite condition deletion
■ partial cleanup of the statistics in the CONTROL-M/Server database (the number of successful
executions for which statistics are retained can be adjusted using the RUNINF_PURGE_LIMIT parameter
in the CONTROL-M [Link] file; Default: 20)
■ partial cleanup of the information in the JOBINF table that is specific to any one instance of a job run
■ User Dailies User Dailies are optional, but when used, they are used with the New Day procedure.
Many sites prefer to split the task of job ordering among multiple User Dailies.
This is especially true if two or more of the following conditions exist:
— The site has a large number of production jobs.
— Jobs can be meaningfully split into different categories.
— Different people manage different jobs.
User Dailies offer several advantages:
— When you use User Dailies, the New Day procedure finishes more quickly.
— User Dailies enable you to schedule jobs at any time during the day. Thus, you can prevent Product
Name from having to load the full day’s production job load at New Day time.
— You can delegate responsibility for User Dailies to other users at your site.
■ ctmorder utility
The ctmorder utility performs job scheduling from a scheduling table in the CONTROL-M/Server
database. You can define jobs that will automatically run this utility.
Control-M Utilities
ctm_agstat
The ctm_agstat utility enables you to list or update the status of an agent, or to delete
an inactive agent.
To display the current status of agent CMAGENT
ctm_agstat -LIST CMAGENT
ctmcheckmirror
The ctmcheckmirror utility checks the mirroring of the CONTROL-M/Server
database and displays the status.
Use the following command to invoke the ctmcheckmirror utility:
ctmcheckmirror
The utility returns one of the following statuses:
_ Mirroring is enabled.
_ Mirroring is disabled.
_ Mirroring is damaged.
ctmcontb
The ctmcontb utility performs the following operations on prerequisite conditions in
the CONTROL-M/Server database:
Lists existing prerequisite conditions while treating an asterisk in a condition name
as a wildcard. (-LIST)
Adds a prerequisite condition. (-ADD)
Generates a prerequisite condition in XML format. (-XML)
Deletes a prerequisite condition while treating an asterisk in a condition name as a
wildcard. (-DELETE)
The following command lists all existing prerequisite conditions:
ctmcontb -LIST "*" "*"
The following command deletes all prerequisite conditions with prefix a and
Condition dates between December 1 and December 15 inclusive:
ctmcontb -DELETEFROM "a*" 1201 1215
ctmcreate
With this control-M utility we can directly create jobs in AJF from command line
The following command contains the minimum parameters required to create a job in
the Active Jobs file:
ctmcreate -tasktype command -group em -application test -cmdline "ls -l /etc/passwd"
ctmdbcheck
The ctmdbcheck utility displays information about the memory capacity and the
status of the CONTROL-M/Server database.
To invoke the ctmdbcheck utility
Ctmdbcheck
Ctmdefine
This utility is used to create job in Control-M DB from command line similar to the task when
we create job using Control-M Desktop
The following command contains the minimum parameters required to create a job in
the Active Jobs file:
ctmdefine -tasktype command -group em -application test -cmdline "ls -l /etc/passwd"
ctmlog
The ctmlog utility creates a report from entries in the CONTROL-M log or deletes entries in the
CONTROL-M log.
The following command produces a report of all entries in the CONTROL-M log between 10:00
A.M. March 12, 2002 and 8:00 A.M. March 14, 2002. The report is output to file [Link] in 80-
column format:
ctmlog list 20020312 1000 20020314 0800 /soft/cm70p701/ctm_server/user1/[Link]
ctmorder
The ctmorder utility orders or forces one or more jobs from a Scheduling table in the
CONTROL-M/Server database.
_ Ordered jobs are placed in the Active Jobs file if their scheduling criteria are met.
_ Forced jobs are placed in the Active Jobs file regardless of their scheduling criteria.
The following command orders all jobs contained in Scheduling table ACCT100. Any
jobs placed in the Active Jobs file will have the current CONTROL-M date as their original
scheduling date:
ctmorder -schedtab ACCT100 -jobname “*” -odate odat
ctmping
The ctmping utility tests, configures, and reports on the connection and availability between
CONTROL-M/Server and CONTROL-M/Agents or remote host computers.
To connect and perform a communication test with the agent jacklin, specify the
following command:
ctmping -nodeid jacklin
The response is:
Agent: jacklin is alive
ctmpsm
The ctmpsm utility can be invoked interactively to display the CONTROL-M Production Support
menu. This menu is used to perform functions affecting jobs or conditions in the active
environment of the data center. It provides an alternative to using the CONTROL-M/EM GUI and
enables you to perform many of the GUI functions directly in the data center.
ctmudlst
The ctmudlst utility is used to display or modify UDLAST
The following command lists the last run date for User Daily payroll:
ctmudlst LIST payroll
The following command changes the last run date for User Daily inventory to Aug. 10, 2002:
ctmudlst UPDATE inventory 20020810
ctmudly
The ctmudly utility orders jobs whose scheduling tables are associated with a specific User
Daily name.
ecactltb
The ecactltb utility displays a list of Control resources and the status of each resource.
To invoke the ecactltb utility, specify the following command
ecactltb [<output>]
<Output> is the full path name to which the report should be sent (optional).
ecaqrtab
The ecaqrtab utility performs operations on the Quantitative Resources table.
These operations include:
_ Listing Quantitative resources.
_ Adding/deleting a Quantitative resource.
_ Manually changing availability of a Quantitative resource.
CONTROL-M/Server database mirroring
Mirroring of the CONTROL-M/Server database allows rapid recovery of CONTROL-M/Server
functionality in the event of a failure of the CONTROL-M/ Server database.
If database mirroring has been implemented and there is a failure of the CONTROL-M/Server
primary database, two options exist for restoring CONTROL-M/Server functionality:
1. Configure CONTROL-M/Server to operate using the mirror database instead of the primary
database. The primary CONTROL-M/Server database can be rebuilt at a later stage.
2. Rebuild the CONTROL-M/Server primary database from the mirror database and start
CONTROL-M/Server again.
Control-M Failover planning
As CONTROL-M is integrated in the production environment of the data center, it
becomes increasingly important to ensure that interruptions of CONTROL-M
functionality are as short as possible.
A properly designed and executed failover plan ensures that CONTROL-M functions
are resumed as soon as possible if a recovery is necessary.
Failover planning for CONTROL-M should provide for the following contingencies:
loss of integrity in the CONTROL-M/Server primary database due to a failure of
the SQL server that maintains the database
failure of the computer on which CONTROL-M/Server runs (server computer)
Ideally, your failover plan should include a complete backup for both the server
computer and the CONTROL-M/Server database.