Oracle Network Products Troubleshooting Guide

Contents Index Home Previous Next

What Is the Difference Between Logging and Tracing?

While logging reveals the state of the Oracle components at the time of an error, tracing provides a description of all software events as they occur, and therefore provides additional information about events prior to an error. The three levels of diagnostics, each providing more information than the previous level, are as follows:

When an error occurs, a simple error message is displayed and a log file is generated. Optionally, a user can generate a trace file for more information. (Remember, however, that using the trace facility has an impact on your system performance.)

In the following example, the user failed to use Oracle Network Manager to create a configuration file, and misspelled the word "PORT" as "POT" in the connect descriptor. It is not important that you understand in detail the contents of each of these results; this example is intended only to provide a comparison between the three levels of diagnostics.

Reported Error

On the screen in SQL*Forms:

ERROR: ORA-12533: TNS:illegal ADDRESS parameters 

Logged Error

In the log file, SQLNET.LOG:

****************************************************************
Fatal OSN connect error 12533, connecting to:
 (DESCRIPTION=(CONNECT_DATA=(SID=trace)(CID=(PROGRAM=)(HOST=lala)
	(USER=ginger)))(ADDRESS_LIST=(ADDRESS=(PROTOCOL=ipc)
	(KEY=bad_port))(ADDRESS=(PROTOCOL=tcp)(HOST=lala)(POT=1521))))

  VERSION INFORMATION:
	TNS for SunOS: Version 2.0.14.0.0 - Developer's Release
	Oracle Bequeath NT Protocol Adapter for SunOS: Version
	2.0.14.0.0 - Developer's Release
	Unix Domain Socket IPC NT Protocol Adaptor for SunOS: Version
   	2.0.14.0.0 - Developer's Release
	TCP/IP NT Protocol Adapter for SunOS: Version 2.0.14.0.0 -
	Developer's Release
  Time: 07-MAY-93 17:38:50
  Tracing to file: /home/ginger/trace_admin.trc
  Tns error struct:
    nr err code: 12206
    TNS-12206: TNS:received a TNS error while doing navigation
    ns main err code: 12533
    TNS-12533: TNS:illegal ADDRESS parameters
    ns secondary err code: 12560
    nt main err code: 503
    TNS-00503: Illegal ADDRESS parameters
    nt secondary err code: 0
    nt OS err code: 0

Example of Trace of Error

The trace file, SQLNET.TRC at the USER level, contains the following information:

--- TRACE CONFIGURATION INFORMATION FOLLOWS ---
New trace stream is "/private1/oracle/trace_user.trc"
New trace level is 4
--- TRACE CONFIGURATION INFORMATION ENDS ---

--- PARAMETER SOURCE INFORMATION FOLLOWS ---
Attempted load of system pfile source /private1/oracle/network/admin/sqlnet.ora
Parameter source was not loaded
Error stack follows:
NL-00405: cannot open parameter file

Attempted load of local pfile source /home/ginger/.sqlnet.ora
Parameter source loaded successfully

 -> PARAMETER TABLE LOAD RESULTS FOLLOW <-
Some parameters may not have been loaded
See dump for parameters which loaded OK
 -> PARAMETER TABLE HAS THE FOLLOWING CONTENTS <-
  TRACE_DIRECTORY_CLIENT = /private1/oracle
  trace_level_client = USER
  TRACE_FILE_CLIENT = trace_user
--- PARAMETER SOURCE INFORMATION ENDS ---

--- LOG CONFIGURATION INFORMATION FOLLOWS ---
Attempted open of log stream "/tmp_mnt/home/ginger/sqlnet.log"
Successful stream open
--- LOG CONFIGURATION INFORMATION ENDS ---

Unable to get data from navigation file tnsnav.ora
local names file is /home/ginger/.tnsnames.ora
system names file is /etc/tnsnames.ora
-<ERROR>- failure, error stack follows
-<ERROR>- NL-00427: bad list
-<ERROR>-   NOTE: FILE CONTAINS ERRORS, SOME NAMES MAY BE MISSING

Calling address: (DESCRIPTION=(CONNECT_DATA=(SID=trace)(CID=(PROGRAM=)(HOST=lala)(USER=ginger)))(ADDRESS_LIST=(ADDRESS=(PROTOCOL=ipc)(KEY=bad_port))(ADDRESS=(PROTOCOL=tcp)(HOST=lala)(POT=1521))))
Getting local community information
Looking for local addresses setup by nrigla
No addresses in the preferred address list
TNSNAV.ORA is not present. No local communities entry.
Getting local address information
Address list being processed...
No community information so all addresses are "local"
Resolving address to use to call destination or next hop
Processing address list...
No community entries so iterate over address list
This a local community access
Got routable address information
Making call with following address information: (DESCRIPTION=(EMPTY=0)(ADDRESS=(PROTOCOL=ipc)(KEY=bad_port)))
Calling with outgoing connect data (DESCRIPTION=(CONNECT_DATA=(SID=trace)(CID=(PROGRAM=)(HOST=lala)(USER=ginger)))(ADDRESS_LIST=(ADDRESS=(PROTOCOL=tcp)(HOST=lala)(POT=1521))))
(DESCRIPTION=(EMPTY=0)(ADDRESS=(PROTOCOL=ipc)(KEY=bad_port)))
KEY = bad_port
connecting...
opening transport...
-<ERROR>- sd=8, op=1, resnt[0]=511, resnt[1]=2, resnt[2]=0
-<ERROR>- unable to open transport
-<ERROR>- nsres: id=0, op=1, ns=12541, ns2=12560; nt[0]=511, nt[1]=2, nt[2]=0
connect attempt failed
Call failed...
Call made to destination
Processing address list so continuing
Getting local community information
Looking for local addresses setup by nrigla
No addresses in the preferred address list
TNSNAV.ORA is not present. No local communities entry.
Getting local address information
Address list being processed...
No community information so all addresses are "local"
Resolving address to use to call destination or next hop
Processing address list...
No community entries so iterate over address list
This a local community access
Got routable address information
Making call with following address information: (DESCRIPTION=(EMPTY=0)(ADDRESS=(PROTOCOL=tcp)(HOST=lala)(POT=1521)))
Calling with outgoing connect data (DESCRIPTION=(CONNECT_DATA=(SID=trace)(CID=(PROGRAM=)(HOST=lala)(USER=ginger)))(ADDRESS_LIST=(ADDRESS=(PROTOCOL=tcp)(HOST=lala)(POT=1521))))
(DESCRIPTION=(EMPTY=0)(ADDRESS=(PROTOCOL=tcp)(HOST=lala)(POT=1521)))

-<FATAL?>- failed to recognize: POT

-<ERROR>- nsres: id=0, op=13, ns=12533, ns2=12560; nt[0]=503, nt[1]=0, nt[2]=0
Call failed...
Exiting NRICALL with following termination result -1
-<ERROR>-  error from nricall
-<ERROR>-    nr err code: 12206
-<ERROR>-    ns main err code: 12533
-<ERROR>-    ns (2)  err code: 12560
-<ERROR>-    nt main err code: 503
-<ERROR>-    nt (2)  err code: 0
-<ERROR>-    nt OS   err code: 0
-<ERROR>- Couldn't connect, returning 12533

In the trace file, note that unexpected events are preceded with an -<ERROR>- stamp. These events may represent serious errors, minor errors, or merely unexpected results from an internal operation. More serious and probably fatal errors are stamped with the -<FATAL?>- prefix.

In this sample trace file, you can see that the root problem, the misspelling of "PORT," is indicated by the trace line: -<FATAL?>- failed to recognize: POT


Contents Index Home Previous Next