How to set up network tracing for Oracle Listener/SQLNET
- Setup listener Trace
- Setup sqlnet.ora trace
- Different Trace Levels
Subdirectory Name
|
Contents
|
alert
|
The XML-formatted log named log.xml
|
cdump
|
Core files
|
incident
|
Multiple subdirectories, where each subdirectory is named for a particular incident, and where each contains dumps pertaining only to that incident
|
trace
|
Background and server process trace files, SQL trace files, and text version of the log.xml file in the alert directory
|
(others)
|
Other subdirectories of ADR home, which store incident packages, health monitor reports, and other information
|
sqlnet.ora File Diagnostic Parameter Comparison
| ||
Parameter
|
DIAG_ADR_ENABLED=OFF
|
DIAG_ADR_ENABLED=ON
|
ADR_BASE
|
Disabled
|
Enabled
|
TRACE_LEVEL_CLIENT
|
Enabled
|
Enabled
|
TRACE_LEVEL_SERVER
|
Enabled
|
Enabled
|
TRACE_DIRECTORY_CLIENT
|
Enabled
|
Disabled
|
TRACE_FILE_CLIENT
|
Enabled
|
Disabled
|
TRACE_UNIQUE_CLIENT
|
Enabled
|
Disabled
|
LOG_DIRECTORY_CLIENT
|
Enabled
|
Disabled
|
LOG_FILE_CLIENT
|
Enabled
|
Disabled
|
LOG_DIRECTORY_SERVER
|
Enabled
|
Disabled
|
TRACE_DIRECTORY_SERVER
|
Enabled
|
Disabled
|
TRACE_FILE_SERVER
|
Enabled
|
Disabled
|
listener.ora File Diagnostic Parameter Comparison
| ||
Parameter
|
DIAG_ADR_ENABLED=OFF
|
DIAG_ADR_ENABLED=ON
|
ADR_BASE_listener_name
|
Disabled
|
Enabled
|
LOGGING_listener_name
|
Enabled
|
Enabled
|
TRACE_LEVEL_listener_name
|
Enabled
|
Enabled
|
TRACE_TIMESTAMP_listener_name
|
Enabled
|
Enabled
|
LOG_DIRECTORY_CLIENT_listener_name
|
Enabled
|
Disabled
|
LOG_FILE_CLIENT_listener_name
|
Enabled
|
Disabled
|
TRACE_DIRECTORY_CLIENT_listener_name
|
Enabled
|
Disabled
|
TRACE_FILELEN_listener_name
|
Enabled
|
Disabled
|
TRACE_FILENO_listener_name
|
Enabled
|
Disabled
|
cman.ora File Diagnostic Parameter Comparison
| ||
Parameter
|
DIAG_ADR_ENABLED=OFF
|
DIAG_ADR_ENABLED=ON
|
ADR_BASE
|
Disabled
|
Enabled
|
LOG_LEVEL
|
Enabled
|
Enabled
|
TRACE_LEVEL
|
Enabled
|
Enabled
|
TRACE_TIMESTAMP
|
Enabled
|
Enabled
|
LOG_DIRECTORY
|
Enabled
|
Disabled
|
TRACE_DIRECTORY
|
Enabled
|
Disabled
|
TRACE_FILELEN
|
Enabled
|
Disabled
|
TRACE_FILENO
|
Enabled
|
Disabled
|
adrci>> SHOW BASE -product client
adrci>> SET BASE -product client
adrci>> SHOW TRACEFILE
adrci>> SHOW TRACE trace_file.trc
adrci>> SHOW SPOOL
adrci>> SHOW TRACEFILE
adrci>> SHOW TRACE trace_file.trc
sqlnet.ora Parameter
|
Oracle Net Manager Field
|
ADR_BASE
|
You must set this parameter manually.
|
DIAG_ADR_ENABLED
|
You must set this parameter manually.
|
LOG_DIRECTORY_CLIENT
|
Client Information: Log Directory
|
LOG_DIRECTORY_SERVER
|
Server Information: Log Directory
|
LOG_FILE_CLIENT
|
Client Information: Log File
|
LOG_FILE_SERVER
|
You must set this parameter manually.
|
listener.ora Parameter
|
Oracle Net Manager Field
|
ADR_BASE_listener_name
|
You must set this parameter manually.
|
DIAG_ADR_ENABLED_listener_name
|
You must set this parameter manually.
|
LOG_DIRECTORY_listener_name
LOG_FILE_listener_name
|
Log File
|
cman.ora Parameter
|
Description
|
ADR_BASE
|
The ADR_BASE parameter specifies the base directory for storing tracing and logging incidents.
Use this parameter when DIAG_ADR_ENABLED is set to ON.
|
DIAG_ADR_ENABLED
|
The DIAG_ADR_ENABLED parameter indicates whether ADR tracing is enabled.
When the DIAG_ADR_ENABLED parameter is set to OFF, non-ADR file tracing is used.
|
EVENT_GROUP
|
The event groups that are logged. Multiple events may be designated using a comma-delimited list. This parameter accepts the following values:
INIT_AND_TERM: initialization and termination MEMORY_OPS: memory operations CONN_HDLG: connection handling PROC_MGMT: process management REG_AND_LOAD: registration and load update WAKE_UP: events related to CMADMIN wakeup queue TIMER: gateway time outs CMD_PROC: command processing RELAY: events associated with connection control blocks
|
LOG_DIRECTORY
|
The destination directory for log files.
By default, the directory is ORACLE_HOME/network/log.
This parameter is disabled when ADR_ENABLED is on.
|
LOG_LEVEL
|
The level of logging. Four levels are supported:
off (default): no logging user: user log information admin: administrative log information support: Oracle Support Services information
|
Setting Logging During Control Utilities Run Time
- For a listener, use the SET LOG_FILE and SET LOG_DIRECTORY commands from the Listener Control utility.
- For an Oracle Connection Manager, use the SET LOG_DIRECTORY, SET LOG_LEVEL, and SET EVENT commands from the Oracle Connection Manager control utility.
sqlnet.ora Parameter
|
Oracle Net Manager Field
|
Description
|
ADR_BASE
|
You must set this parameter manually.
|
The ADR_BASE parameter specifies the base directory for storing tracing and logging incidents.
Use this parameter when DIAG_ADR_ENABLED is set to ON.
|
DIAG_ADR_ENABLED
|
You must set this parameter manually.
|
The DIAG_ADR_ENABLED parameter indicates whether ADR tracing is enabled.
When the DIAG_ADR_ENABLED parameter is set to OFF, non-ADR file tracing is used.
|
LOG_DIRECTORY_CLIENT
|
Client Information: Log Directory
|
The destination directory for the client log file. By default, the client directory is the current working directory. This parameter is disabled when ADR_ENABLED is on.
|
LOG_DIRECTORY_SERVER
|
Server Information: Log Directory
|
The destination directory for the database server log files. By default the server directory is ORACLE_HOME/network/log. This parameter is disabled when ADR_ENABLED is on.
|
LOG_FILE_CLIENT
|
Client Information: Log File
|
The name of the log file for the client. By default the log name is sqlnet.log.
|
LOG_FILE_SERVER
|
You must set this parameter manually.
|
The name of the log file for the database server. By default the log name is sqlnet.log.
|
TRACE_DIRECTORY_CLIENT
|
Client Information: Trace Directory
|
The destination directory for the client trace output. By default, the client directory is ORACLE_HOME/network/trace.
|
TRACE_DIRECTORY_SERVER
|
Server Information: Trace Directory
|
The destination directory for the database server trace output. By default, the server directory is ORACLE_HOME/network/trace.
|
TRACE_FILE_CLIENT
|
Client Information: Trace File
|
The name of the trace file for the client. By default, the trace file name is sqlnet.trc.
|
TRACE_FILE_SERVER
|
Server Information: Trace File
|
The name of the trace file for the database server. By default the trace file name is svr_pid.trc.
|
TRACE_FILELEN_CLIENT
|
You must set this parameter manually.
|
The size of the client trace files in KB. When the size is reached, the trace information is written to the next file. The number of files is specified with the TRACE_FILENO_CLIENT parameter.
|
TRACE_FILELEN_SERVER
|
You must set this parameter manually.
|
The size of the database server trace files in KB. When the size is reached, the trace information is written to the next file. The number of files is specified with the TRACE_FILENO_SERVER parameter.
|
TRACE_FILENO_CLIENT
|
You must set this parameter manually.
|
The number of trace files for client tracing. When this parameter is set along with the TRACE_FILELEN_CLIENT parameter, trace files are used in a cyclical fashion. The first file is filled, then the second file, and so on. When the last file has been filled, the first file is re-used, and so on.
The trace file names are distinguished from one another by their sequence number. For example, if the default trace file of sqlnet.trc is used, and this parameter is set to 3, then the trace files would be named sqlnet1_pid.trc, sqlnet2_pid.trc and sqlnet3_pid.trc.
In addition, trace events in the trace files are preceded by the sequence number of the file.
|
TRACE_FILENO_SERVER
|
You must set this parameter manually.
|
The number of trace files for database server tracing. When this parameter is set along with the TRACE_FILELEN_SERVER parameter, trace files are used in a cyclical fashion. The first file is filled, then the second file, and so on. When the last file has been filled, the first file is re-used, and so on.
The trace file names are distinguished from one another by their sequence number. For example, if the default trace file of svr_pid.trc is used, and this parameter is set to 3, then the trace files would be named svr1_pid.trc, svr2_pid.trc and svr3_pid.trc.
In addition, trace events in the trace files are preceded by the sequence number of the file.
|
TRACE_LEVEL_CLIENT
|
Client Information: Trace Level
|
The level of detail the trace facility records for the client.
The trace level value can either be a value within the range of 0 (zero) to 16 where 0 is no tracing and 16 represents the maximum amount of tracing) or one of the following values:
off (equivalent to 0) provides no tracing. user (equivalent to 4) traces to identify user-induced error conditions. admin (equivalent to 6) traces to identify installation-specific problems. support (equivalent to 16) provides trace information for troubleshooting information for Oracle Support Services.
|
TRACE_LEVEL_SERVER
|
Server Information: Trace Level
|
The level of detail the trace facility records for the database server. The trace level value can either be a value within the range of 0 (zero) to 16 where 0 is no tracing and 16 represents the maximum amount of tracing) or one of the following values:
off (equivalent to 0) provides no tracing. user (equivalent to 4) traces to identify user-induced error conditions. admin (equivalent to 6) traces to identify installation-specific problems. support (equivalent to 16) provides trace information for troubleshooting information for Oracle Support Services.
|
TRACE_TIMESTAMP_CLIENT
|
You must set this parameter manually.
|
A time stamp in the form of dd-mon-yyyy hh:mi:ss:mil for every trace event in the client trace file, sqlnet.trc.
|
TRACE_TIMESTAMP_SERVER
|
You must set this parameter manually.
|
A time stamp in the form of dd-mon-yyyy hh:mi:ss:mil for every trace event in the client trace file, sqlnet.trc.
|
TRACE_UNIQUE_CLIENT
|
Client Information: Unique Trace File Name
|
The value is set to on, Oracle Net creates a unique file name for each trace session by appending a process identifier to the name of each trace file generated, and enabling several files to coexist. For example, trace files named sqlnetpid.trc are created if default trace file name sqlnet.trc is used. When the value is set to off, data from a new client trace session overwrites the existing file.
|
TNSPING Trace Parameters
| |
sqlnet.ora Parameter
|
Description
|
TNSPING.TRACE_DIRECTORY
|
The destination directory for TNSPING trace file, tnsping.trc. By default, the directory is ORACLE_HOME/network/trace.
|
TNSPING.TRACE_LEVEL
|
The level of detail the trace facility records for the TNSPING utility. The trace level value can either be a value within the range of 0 (zero) to 16 where 0 is no tracing and 16 represents the maximum amount of tracing) or one of the following values:
off (equivalent to 0) provides no tracing. user (equivalent to 4) traces to identify user-induced error conditions. admin (equivalent to 6) traces to identify installation-specific problems. support (equivalent to 16) provides trace information for troubleshooting information for Oracle Support Services.
|
listener.ora Parameter
|
Oracle Net Manager Field
|
Description
|
ADR_BASE_listener_name
|
You must set this parameter manually.
|
The ADR_BASE_listener_name parameter specifies the base directory for storing which tracing and logging incidents.
Use when DIAG_ADR_ENABLED_listener_name is set to ON.
|
DIAG_ADR_ENABLED_listener_name
|
You must set this parameter manually.
|
The DIAG_ADR_ENABLED_listener_name parameter indicates whether ADR tracing is enabled.
When DIAG_ADR_ENABLED_listener_name is set to OFF, non-ADR file tracing is used.
|
LOG_DIRECTORY_listener_name
LOG_FILE_listener_name
|
Log File
|
The destination directory and file for the log file that is automatically generated for listener events. By default the directory is ORACLE_HOME/network/log, and the file name is
|
listener.ora Parameter
|
Oracle Enterprise Manager/Oracle Net Manager Field
|
Description
|
TRACE_LEVEL_listener_name
|
Select a trace level/Trace Level
|
The level of detail the trace facility records for the listener. The trace level value can either be a value within the range of 0 (zero) to 16 where 0 is no tracing and 16 represents the maximum amount of tracing) or one of the following values:
off (equivalent to 0) provides no tracing. user (equivalent to 4) traces to identify user-induced error conditions. admin (equivalent to 6) traces to identify installation-specific problems. support (equivalent to 16) provides trace information for troubleshooting information for Oracle Support Services.
|
TRACE_DIRECTORY_listener_name
TRACE_FILE_listener_name
|
Trace File
|
The destination directory and file for the trace file. By default the directory is ORACLE_HOME/network/trace, and the file name is listener.trc.
|
TRACE_FILELEN_listener_name
|
You must set this parameter manually.
|
The size of the listener trace files in KB. When the size is reached, the trace information is written to the next file. The number of files is specified with the TRACE_FILENO_listener_name parameter
|
TRACE_FILENO_listener_name
|
You must set this parameter manually.
|
The number of trace files for listener tracing. When this parameter is set along with the TRACE_FILELEN_listener_name parameter, trace files are used in a cyclical fashion. The first file is filled, then the second file, and so on. When the last file has been filled, the first file is re-used, and so on.
The trace file names are distinguished from one another by their sequence number. For example, if the default trace file of listener.trc is used, and this parameter is set to 3, then the trace files would be named listener1.trc, listener2.trc and listener3.trc.
In addition, trace events in the trace files are preceded by the sequence number of the file.
|
TRACE_TIMESTAMP_listener_name
|
You must set this parameter manually.
|
A time stamp in the form of dd-mon-yyyy hh:mi:ss:mil for every trace event in the listener trace file.
|
Using the Trace Assistant to Examine Trace Files
- 0 or nothing translates the NS error numbers dumped from the nserror function plus lists all other errors
- 1 displays only the NS error translation from the nserror function
- 2 displays error numbers without translation
- Socket ID, if the connection has one.
- Connect packet send or receive operation.
- Current setting of the MULTIPLEX attribute of the DISPATCHERS parameter in the initialization parameter file. When MULTIPLEX is set to ON, session multiplexing is enabled.
- Session ID, if MULTIPLEX is set to ON.
- Connect data information.
- Do not use this option with other options.
- The IDs generated by the Trace Assistant do not correlate with client/server trace files.
- c to display summary connectivity information.
- d to display detailed connectivity information.
- u to display summary Two-Task Common (TTC) information.
- t to display detailed TTC information.
- q to display SQL commands enhancing summary TTC information. Use this option with u, such as -ouq.
- Total number of bytes sent and received.
- Maximum open cursors.
- Currently open cursors.
- Count and ratio of operations.
- Parsing and execution count for PL/SQL.
- Total calls sent and received.
- Total, average, and maximum number of bytes sent and received.
- Total number of transports and sessions present.
- Timestamp information, if any.
- Sequence numbers, if any.
No comments:
Post a Comment