Enabling and disabling the tasks that automatically rotate message log files
Before the database server can run the built-in Scheduler tasks that automatically rotate message log files, you must enable each task that rotates a message log file. You only need to enable each task once. You can also disable an enabled task.
About this task
Procedure
To enable a task for rotating logs:
t
(true)
for the message log file where the tk_name column is the name
of the message log, as follows: UPDATE ph_task SET tk_enable = t , tk_frequency = frequency
WHERE tk_name = name_of_message_log task";
The
name of the message log must be bar_act_log_rotate
, bar_debug_log_rotate
,
or online_log_rotate.
For example, to enable the online_log_rotate task and set the frequency of the task to every 30 days, specify:
DATABASE sysadmin;
UPDATE ph_task SET tk_enable = "t" ,
tk_frequency = INTERVAL (30) DAY TO DAY
WHERE tk_name = "online_log_rotate";
You can also specify tk_frequency = tk_frequency
if
you do not want to accept the default frequency (3:00 A.M. every 30
days) when you enable the task.
What to do next
The only possible values for tk_enable
are t
and f
(true
and false).
To disable the running of a message log rotation
task, set tk_enable
to f
, as shown
in the following example:
UPDATE ph_task SET tk_enable = "f" ,
tk_frequency = INTERVAL (30) DAY TO DAY
WHERE tk_name = "bar_debug_log_rotate";
You can also
specify tk_frequency = tk_frequency
if you want to
accept the default frequency (3:00 A.M. every 30 days).