|Oracle Network Products Troubleshooting Guide||
Log files automatically record connection errors for clients, servers, listeners, and Names Servers. Logging cannot be turned off for most components. In addition, the listener log file contains Audit Trail information about all connection requests and the results of Listener Control Utility commands.
Logging for the Connection Manager and pumps and the Navigator is optional; you can turn it on and off through Oracle Network Manager. The default is for logging to be off. Logging for these components includes statistical information. You can also request the Navigator to log more detailed information.
Table 2 - 1. Log Parameters and Component Configuration Files
|Log Parameters Corresponding to||Configuration File|
|Connection Manager and pumps|
See the Oracle operating system-specific documentation for your platform to determine where these files are expected to reside and where you can find sample files.
Note: The Connection Manager and Navigator log file location cannot be modified using Oracle Network Manager. Use the default location for your platform.
Note: There is usually a single SQLNET.ORA file for all the clients and servers on a node. That file would contain log parameters for both clients and servers. Generally all clients on a node will have similar logging requirements, as will all servers.
Log parameters are entered in the appropriate component configuration files in the form:
log_parameter_component = value
The component is one of listener name, client, server, Connection Manager, Navigator, or Names Server.
Note: All log parameters except those for the listener are entered with their component's generic name (for example, navigator). Listener log parameters are entered with the name of the specific listener (for example, LISTENER2). However, the server is the only component for which you should configure log parameters manually. All other components are configured using Oracle Network Manager.
Contains client and/or server information
Contains listener information
Contains Connection Manager and pump information
Contains Navigator information
Contains Names Server information
You can control the name of the log file. For each component, any valid string can be used to create a log filename. The parameters are of the form:
LOG_FILE_component = string
LOG_FILE_LISTENER = TEST
This parameter would send listener log output to a file called TEST.LOG on the server machine. On most operating systems, the .log suffix is automatically appended to the log filename. Therefore, do not include a suffix in the log filename string.
Some platforms have restrictions on the properties of a filename. See your Oracle operating system-specific manuals for platform-specific restrictions.
LOG_DIRECTORY_component = valid directory
Examples are specific to different operating systems. An example on UNIX might be:
LOG_DIRECTORY_LISTENER = /tmp/log
Some platforms have restrictions on the properties of a directory. See your Oracle operating system-specific manuals for platform-specific restrictions.
A single option, Level, determines whether logging is activated for the Connection Manager and the Navigator. The choices and their consequences are as follows:
No logging for either the Connection Manager or the Navigator. This is the default.
Logging is on for the Connection Manager (and pumps), but not the Navigator.
Logging is on for the Connection Manager (and pumps), and all errors of navigation are logged for the Navigator.
Logging is on for the Connection Manager (and pumps), and all navigation requests are logged for the Navigator.
Note: See the Oracle Network Manager Administrator's Guide for how to set logging parameters for all the network objects.
TIMESTAMP*CONNECT DATA[* PROTOCOL INFO]*EVENT [*SID]*RETURN CODE
Each field is delimited by an asterisk (*).
Both PROTOCOL INFO and SID appear only when a connection is attempted. Only four fields are passed in response to a listener control command.
A successful connection or command returns a code of 0. A failure produces a code that maps to an error message.
10-MAY-95 14:16:21 *(CONNECT_DATA=(CID=(PROGRAM=)(HOST=roach)(USER=reltest) (COMMAND=reload)(ARGUMENTS=64)(SERVICE=LISTENER) (VERSION=36704256))*reload*0
10-MAY-95 14:16:21*(CONNECT_DATA=(SID=reltest)(CID= (PROGRAM=C:\ORAWIN\BIN\PLUS31.EXE) (HOST=WINDOWSPC)(USER=CCLOW))*(ADDRESS=(PROTOCOL=tcp) (HOST=220.127.116.11)(PORT=3366)) *establish*reltest*0
Notice that the user ID is recorded as well as the platform, protocol, and software used to make the connection.
Use a script to load the client connection event information from the listener log file. To use it, you must have a database to accomodate it. Therefore, before running the script, create a table with the following structure:
CREATE TABLE A_TRAIL (TIMESTAMP VARCHAR2 (20), CONNECTDATA CHAR (80), PROTOCOL_INFO VARCHAR2 (60), EVENT CHAR (15), SID CHAR (15), RETURN_CODE NUMBER (2));
The following sample SQL*Loader script is stored as a_trail.ctl. It looks like this:
LOAD DATA INFILE LISTENER.LOG APPEND INTO TABLE a_trail FIELDS TERMINATED BY "*" (TIMESTAMP, CONNECTDATA, PROTOCOL_INFO, EVENT, SID, RETURN_CODE)
To run the script, enter:
sqlldr username/password a_trail.ctl
Copyright © 1996 Oracle Corporation.
All Rights Reserved.