| Lesson 4 | Oracle tracing parameters |
| Objective | Describe the functions of Oracle trace parameters and explain why they are still relevant in Oracle 26ai. |
init.ora, along with sqlnet.ora and listener.ora. That file format is not deprecated; init.ora (a PFILE) is still fully supported today, it is simply less convenient for ongoing administration than a server parameter file (SPFILE), which supports persistent ALTER SYSTEM changes without manual file editing; see Additional Database Parameters for the distinction. In Oracle 26ai, the same tracing ideas still apply regardless of which parameter file style is in use, but the diagnostic infrastructure has evolved around the Automatic Diagnostic Repository (ADR). Understanding the original parameters helps you read legacy documentation and maintain older systems, while the modern view shows how they map into 26ai.
SQL > show parameters dump
NAME TYPE VALUE
----------------------------------- ------- ------------------------------
background_core_dump string full
background_dump_dest string ?/rdbms/log
core_dump_dest string ?/dbs
max_dump_file_size string 10240
shadow_core_dump string full
user_dump_dest string ?/rdbms/log
background_dump_dest: directory for background process trace files (LGWR, DBWn, SMON, PMON, and so on).user_dump_dest: directory for user server process trace files (for example, SQL trace for a specific session).core_dump_dest, background_core_dump, shadow_core_dump: control where and how core files are written.max_dump_file_size: prevents runaway trace from consuming unlimited disk space.$ORACLE_HOME/rdbms/log:
dilbert> cd $ORACLE_HOME/rdbms/log
dilbert> ls
alert_fred.log
reco_34326.trc
smon_57560.trc
snp1_54580.trc
ora_58718.trc
dbwr_38406.trc
lgwr_36106.trc
pmon_52070.trc
alert_fred.log: the alert log for the fred database, historically stored with background traces.pmon_*.trc, smon_*.trc, dbwr_*.trc, lgwr_*.trc: trace files for specific background processes.reco_*.trc: trace produced by the Recoverer process.ora_*.trc: generic server process traces, often connected to user sessions or jobs.BACKGROUND_DUMP_DEST and USER_DUMP_DEST, you configure DIAGNOSTIC_DEST, and Oracle derives the underlying directories automatically.
DIAGNOSTIC_DEST (typically something like $ORACLE_BASE/diag/rdbms/DB_UNIQUE_NAME/INSTANCE_NAME/trace). You view and manage these files using standard tools and the adrci utility, but the conceptual mapping is unchanged:
background_dump_dest or user_dump_dest, think of them as an older way to say "where the ADR trace directory lives." Oracle 26ai formalizes that concept with DIAGNOSTIC_DEST and ADR.
sqlnet.ora on both client and server. In Net8-era documentation you will often see references to sqlnet.trc for the client and svr_pid.trc for the server; these remain the current default trace file names, even though "Net8" itself is a legacy name for what is now simply Oracle Net. Modern 26ai environments still support these file names, but tracing integrates with ADR when DIAG_ADR_ENABLED is turned on, and current deployments more often reach for Easy Connect Plus or an OCI-native connection method than classic Net8-style naming; see Oracle 23ai OCI Service Connection Methods for the current approach.
off (0), user (4), admin (6), and support (16) control the amount of detail generated. Oracle Connection Manager is the one component where admin maps to 10 instead of 6; for the client, server, and listener, it is 6.sqlnet.ora under paths like c:\orant\network\admin or $ORACLE_HOME/network/admin. The exact directory changes between releases and deployment styles (on-premises, Instant Client, or OCI), but the idea remains: sqlnet.ora is the central place where you enable or disable network tracing.
sqlnet.ora, it is also worth setting sane connection timeouts alongside your tracing parameters, so a stuck connection attempt fails fast enough to leave a useful trace entry rather than hanging indefinitely; see Setting TNS Timeout Values for the outbound, inbound, send, and receive timeout settings.
listener.ora.
TRACE_LEVEL_listener_name minimal day to day and lean on ADR's own diagnostics first; when you do need to change it, lsnrctl help (or lsnrctl help trace) from the Listener Control utility always reflects the exact syntax your installed release supports, which is more reliable than any static table. See the LSNRCTL Help Utility for more on using it.
| listener.ora Parameter | OEM Cloud Control/Net Manager Field | Description |
| TRACE_LEVEL_listener_name | Select a trace level / Trace Level |
Controls the level of detail written to the listener trace file. The value can be either a number between 0 and 16 (0 = no tracing, 16 = maximum tracing) or one of the following keywords:
off and enable tracing temporarily for a specific troubleshooting session.
|
| TRACE_DIRECTORY_listener_name TRACE_FILE_listener_name |
Trace File |
Specifies the destination directory and file name for listener trace output when non-ADR tracing is in use. By default, the directory is ORACLE_HOME/network/trace and the file name is listener.trc. In ADR-enabled environments, the effective trace directory is under the ADR base instead, but the conceptual role of these parameters is the same: they determine where listener trace data is written.
|
| TRACE_FILEAGE_listener_name | Set manually |
Specifies the maximum age of listener trace files in minutes. When the age limit is reached, tracing continues in the next file. The maximum number of trace files is controlled by TRACE_FILENO_listener_name.
|
| TRACE_FILELEN_listener_name | Set manually |
Sets the maximum size of a listener trace file in kilobytes. When this size is reached, trace output is redirected to the next file. Use this parameter together with TRACE_FILENO_listener_name to prevent diagnostic files from consuming too much storage.
|
| TRACE_FILENO_listener_name | Set manually |
Specifies how many listener trace files are used in a cyclical fashion. The first file is filled, then the second, and so on. After the last file reaches its age or size limit, the first file is reused.
For example, if the base file name is listener.trc and this parameter is set to 3, the files will be named listener1.trc, listener2.trc, and listener3.trc. Traces within these files are tagged with the file sequence number, making it easier to associate events with a particular tracing window.
|
| TRACE_TIMESTAMP_listener_name | Set manually |
Adds a timestamp of the form dd-mon-yyyy hh:mi:ss:mil to every listener trace event. Timestamps are essential when you correlate trace output with application logs, OS logs, or database alert logs.
|
support level for stubborn issues. Knowing how to enable and control tracing saves time during SR handling.tkprof, trace parameters provide detailed performance data down to the session level.adrci) and views for querying incidents and problems.DIAGNOSTIC_DEST when working with Oracle 26ai.
init.ora dump parameters through classic sqlnet.ora/listener.ora trace files to ADR. Every component, the database instance, the listener, the client and server, and Oracle Connection Manager, exposes the same basic controls: a level that decides how much detail gets written, a location for the resulting output, and a rotation scheme so that output doesn't grow without bound. Learning that pattern once, rather than memorizing each component's parameter names in isolation, is what makes legacy documentation readable and new documentation unsurprising. The specific parameter names in this lesson will keep showing up in older scripts, forum answers, and sample configurations for years to come; knowing what they map to in a current, ADR-based 26ai environment is what turns that old material from a liability into a still-useful reference.