Use Logger commands to configure Logger for extracting data changes from non-TMF applications.
Logger processes default to a prefix of $GGL
. To change these default settings, see Change Synchronization for Non-TMF Applications.
Use ADD
LOGGER
to configure GGSLIB
and Logger. By default, ADD
LOGGER
reads a parameter file called GGS_volume
.GGSPARM
.LOGPARM
. Before invoking ADD LOGGER
, edit LOGPARM
to enter the appropriate parameters. See "Logger Parameters Summary" for information about the parameters you can enter into this file.
To bind GGSLIB
to the application, see "Programs commands".
Syntax
ADD LOGGER [, PARAMS param_file_name]
ADD LOGGER
performs the following:
Validates the configuration parameters for Logger.
Creates a segment file containing parameters used by GGSLIB
intercept library routines. These parameters tell the intercepts where to send logged information (that is, which Loggers should receive it).
The default segment file is $SYSTEM.GGS.AUDCFG
. It is strongly recommended that you use the default location. If you must use a different location (such as for running multiple occurrences of the Oracle GoldenGate environment), see Changing Default Component Names.
If the segment file exists at the time ADD LOGGER
is issued, GGSCI renames the existing segment and issues a message informing you the existing AUDCFG
is renamed.
Creates log trail files and pre-allocates space for the log trails. GGSCI has a limit of 200 log trails per Logger process. The maximum number of Logger processes per instance is 50.
Updates the GGS database to recognize the Loggers and configuration parameters.
Use ALTER LOGGER
to change parameters for an existing Logger process. As with the ADD LOGGER
command, ALTER LOGGER
reads and validates the parameters in LOGPARM
and pre-allocates log trail files.
Syntax
ALTER LOGGER [, PARAMS param_file_name]
Configuration segment files are aged every time ALTER LOGGER
is invoked (AUDCFG00, AUDCFG01
, and so on). If the segment file exists at the time ALTER LOGGER
is issued, GGSCI renames the existing segment and issues a message informing you the existing AUDCFG
is renamed. ALTER LOGGER
renames up to 99 files.
Logger parameter changes take effect immediately. Altering Logger parameters while Logger or Replicat processes are running requires careful consideration. In particular, consider the situation in which a file set is switched from one Logger to another.
If you execute commands for ALTER
LOGGER
that change what files are logged to which Logger process, expect to see a message similar to the following:
14-11-12;12:23:28:22.964 \NY,3,28 ORACLE.1.H06 512 FILE \NY.$DATA04,TEST1.ABC switched to logger \NY.$KK00
Use DELETE LOGGER
to delete the internal Oracle GoldenGate Logger configuration files created when you entered ADD LOGGER
.
Optionally, you can also delete the Logger trails with the ! (exclamation point) option. Before executing this option, ensure that all of the data has been processed out of the trail.
Use INFO LOGGER
to retrieve the following information about Logger:
The location of the shared configuration segment used by GGSLIB
The date Logger was added and the location of the parameter file used to create it
The settings for timeout and debug, and whether logging is currently on
Which sequence number Logger currently has open for each Logger process
CPU, BACKUPCPU
and PRIORITY
values for each process
Whether the trail is version 7 format (New) or the format from before version 7 (Old)
FILE
entries for each Logger process, along with the settings for the following FILE
configuration options for each file
Syntax
INFO LOGGER [, AUDCFG segment_file] [, SHOWLOGGED file_name [, PROGRAM program_set | PROCESS process_set | USER user_set]] [, BRIEF]
AUDCFG
segment_file
Determines the parameters for any configuration, including the current one. Configuration segment files are aged every time ALTER LOGGER
is invoked (AUDCFG00, AUDCFG01
, and so on).
BRIEF
Limits the INFO LOGGER
display to information about the SHOWLOGGED
file name.
SHOWLOGGED
file_name
Lets you determine which log process, if any, is capturing a particular file. Specify the file name or wildcard file set. Whether the file is included, excluded or omitted for each Logger is displayed.
If you specify SHOWLOGGED
, you can also detect whether a file is included or excluded according to one of the following:
PROCESS
process_set
Directs Logger to extract data only when the opener is the process or set of processes specified. (The process set can be a single process or a wildcard, for example $APP*.
)
PROGRAM
program_set
Directs Logger to extract data only when the opener is the program or set of programs specified. (The program set can be a single program or a wildcard, for example $DATA1.PROGS.*
.)
USER
user_set
Directs Logger to extract data only when the creator access ID of the opener is the user specified. (The user set can be a single user, for example FINANCE.JOE
, or a wildcard, for example SUPER.*
.)
Example
Sample results from an INFO
LOGGER
command:
Information for Logger Group $GGL Intercept segment file \NY.$SYSTEM.GGS.AUDCFG Created 2010-10-21 11:24 Built from \NY.$DATA01.GGSPARM.LOGPARM Logger timeout: 60.00 seconds Debug on stack check: Off Current mode: Logging is ON Process: $GGL49 Log Trail: \NY.$DATA01.LOGGER.ET000013 Status: DOWN CPUs: 2,3 Priority: 170 Logopens: 16 Flush recs: 16 Flush secs: 0.85 Trace IOs: Off Trace Stats: Off Heartbeat: Off AdjustPriority: On BlockSize: 57344 TrailFormat: New SourceAppInfo: Included Logger Timeout: 60.00 seconds Comp Unstr TMF Bulk Rename Log Files Updts Files Files IO Delay Mode \NY.$D*.*.* No Yes No Yes No Normal
Syntax
SEND LOGGER [, PROCESS process_name] [, ADJUSTPRIORITY | NOADJUSTPRIORITY] [, ROLLOVER] [, REFRESH] [, PROCESSINFO [, DETAIL]] [, LOGFILECLOSEDELAY seconds] [, LOGINFO] [, FLUSHSTATS [, FILTERPROCESS process_name | FILTERPROGRAM program_name | FILTERLIBRARY library_name] | [, RESET]] [, GETSTATS [, FILTERPROCESS process_name | FILTERPROGRAM program_name | FILTERLIBRARY library_name] | [, RESET]] [, GETLOGFILECLOSEDELAY] [, HOTSWAP object_name]
PROCESS
process_name
Sends to the named process. Otherwise, the command is sent to all Logger processes in the default Logger group ($GGL*
).
ADJUSTPRIORITY | NOADJUSTPRIORITY
Determines how Logger adjusts its priority in relation to the sender priority.
Logger checks at 1 minute intervals to determine if there was a high priority sender during the previous interval. If not, by default, Logger sets its priority back down to the original value.
To retain the value set by the sender, specify ADJUSTPRIORITY
, as in:
GGSCI SEND LOGGER, ADJUSTPRIORITY
If NOADJUSTPRIORITY
is in effect Logger does not increase its priority to match that of a higher priority sender.
ROLLOVER
Instructs Logger to move to the next log file in the log trail sequence.
REFRESH
Instructs Logger to read its LOGCONF
record to pick up configuration option changes.
PROCESSINFO
Instructs Logger to return input and output statistics, lag, and other information to the screen. Optionally, include DETAIL
to report process details.
LOGFILECLOSEDELAY
Sets the time to delay closing the old file when rolling to a new one. Logger starts the timer, writes to the new file and closes the old file when the timer is reached or when it rolls to another new file. The default value is 120 seconds.
LOGINFO
Displays information on Logger's current log file.
FLUSHSTATS
Instructs Logger to output current process statistics to the log trail. Optionally, include RESET
to reset all statistics counters to zero.
You can specify one of the following filters per SEND LOGGER FLUSHSTATS
command.
FILTERPROCESS
process_name
FILTERPROGRAM
program_name
FILTERLIBRARY
library_name
These allow you to restrict flushed information to the specified process, program, or library. The name is the specified process, program, library, or a wildcard. Use only one of these options.
GETSTATS
Outputs current process statistics to the screen.
If you specify GETSTATS
, you must specify either TRACESTATS
or TRACEPROCESSIOS
in the Logger parameter file.
Optionally, include RESET
to reset all statistics counters to zero.
You can specify one of the following filters per SEND LOGGER GETSTATS
command.
FILTERPROCESS
process_name
FILTERPROGRAM
program_name
FILTERLIBRARY
library_name
These allow you to restrict flushed information to the specified process, program, or library. The name is the specified process, program, library, or a wildcard. Use only one of these options.
GETLOGFILECLOSEDELAY
Outputs the current value for LOGFILECLOSEDELAY
.
HOTSWAP
object_name
Instructs Logger to use the specified object file. Allows a running Logger to be changed to a different Logger object.
Caution: The HOTSWAP
command must be performed with the manual steps used to upgrade BASELIB
as part of the upgrade process.
Use this command to stop a group of Logger processes. By default, this group is $GGL
.
If some log processes are down, STOP LOGGER
brings down the remainder. Use this command cautiously, since no data is logged while log processes are down. When issuing this command, you will be prompted to specify whether you want to continue.
Use STOP LOGGER
instead of stopping log processes individually from TACL. By default, Manager restarts log processes stopped from TACL.
Syntax
STOP LOGGER [, NAME process_name] [!]
NAME
process_name
To stop a particular process within the group, specify the full name of the process (for example, $GGL01
).
!
When you issue STOP LOGGER
, with or without options, you are prompted to confirm the operation. To override the prompt, include !
(exclamation point) in the command argument.