Oracle(R) Enterprise Manager Oracle(R) Trace User's Guide
Release 2.0

A67837-01

Library

Product

Contents

Index

Prev Next

C
Troubleshooting Oracle Trace

This appendix lists the problems you might encounter while using Oracle Trace. Solutions to these problems are provided, as well as a section on how to isolate problems encountered while using Oracle Trace. Sections in this appendix include:

Typical Problems Encountered While Using Oracle Trace

Table C-1 lists the symptoms Oracle Trace can exhibit, provides solutions, and refers you to the appropriate section for additional information. The table is also divided into sections which reflect how you would use Oracle Trace in the context of a collection.

Table C-1 Typical Problems Encountered While Using Oracle Trace
Symptom  Solution 
Prior to Scheduling Collection  

"Authentication User" error during product discovery.  

Preferences for node are invalid or not set.

See "Oracle Enterprise Manager Configuration".  

Products not discovered.  

Product definition files might be missing.

See "Oracle Trace Configuration".  

"Failed to connect to agent" during product discovery.  

Cannot connect to Oracle Intelligent Agent.

See "Network Configuration".

See "Oracle Intelligent Agent (UNIX Specific)".

See "Oracle Intelligent Agent (NT Specific)".  

Database missing from product discovery.  

Verify oratab file is on the server. If file exists, verify contents of oratab file.

See "Oracle Intelligent Agent (UNIX Specific)".  

Oracle Trace discovery fails while processing files for a 7.3 ORACLE_HOME.  

Oracle Trace discovery process may have encountered a pre-7.3.3 otrccol image which is not compatible with Oracle Trace Manager.

See "Server Environment".  

Creating Collection  

Cannot connect to Show User List.  

Edit the tnsnames.ora file and add a service name that matches the service name known to the Oracle Enterprise Manager console.

See "Failure Connecting to Show User List".  

Scheduling Collection  

Cannot start Oracle Trace from Oracle Enterprise Manager console.  

Start Oracle Trace using Start menu or reinstall Oracle Trace.  

No nodes listed in Oracle Trace Manager.  

In Oracle Enterprise Manager console, discover nodes that you want to manage by choosing Navigator=> Discover Nodes, then perform product discovery in Oracle Trace Manager.

See "Oracle Enterprise Manager Configuration".  

"Authentication User" error during collection creation.  

Preferences for node are invalid or not set.

See "Oracle Enterprise Manager Configuration".  

"Could not read file <filespec>".  

File not in expected location.

See "Oracle Trace Configuration".  

Error starting/stopping Oracle7 database collection.  

There are missing database stored procedures that Oracle Trace uses to start and stop an Oracle7 database collection.

See "Stored Procedures".  

Oracle Trace Manager shows collection with status 'Created' and Oracle Enterprise Manager Job system shows collection "awaiting agent confirmation".  

Cannot connect to Oracle Intelligent Agent.

See "Network Configuration".

See "Oracle Intelligent Agent (UNIX Specific)".

See "Oracle Intelligent Agent (NT Specific)".  

Oracle Trace Manager shows collection with status 'Created' and Oracle Enterprise Manager Job system shows collection with changing status.  

Oracle Intelligent Agent messages are not returned to Oracle Trace Manager.

Exit and restart Oracle Trace Manager.

Exit and restart Oracle Enterprise Manager console and Oracle Trace Manager.  

Executing Collection  

Error finding executable or command.  

Preference setting node has invalid path.

See "Server Environment".  

"Could not read file <filespec>".  

File not in expected location.

See "Oracle Trace Configuration".  

Network timeout.  

See "Network Configuration".  

Error accessing memory for collections running on NT server nodes.  

See "Oracle Trace Could Not Access Memory".  

Error starting collection on server node.  

See "Database Configuration".

See "Oracle Trace Configuration".  

Error starting NT database collection, with memory mapping error.  

See "Oracle Trace Configuration" for discussion of mismatch between NT database and Oracle Trace Collection Services.  

Collection does not end at scheduled time.  

Possibly out of disk space or Oracle Intelligent Agent is not available.

See "Server Environment".

See "Network Configuration".

See "Oracle Intelligent Agent (UNIX Specific)".

See "Oracle Intelligent Agent (NT Specific)".  

Formatting Collection  

Format gets "unable to resolve service name" error.  

Database not available or invalid tnsnames.ora file on server.

See "Network Configuration".

See "Database Configuration".  

Format gets "invalid username/password" error.  

Preferences setting for database is invalid or not set.  

Format gets "table does not exist" error (Oracle Server release 7.3.x and earlier).  

Formatter tables not created.

See "Database Configuration".

See "Formatter Tables".  

Format gets error extending tablespace.  

Insufficient space in target tablespace in the database to which you are formatting. Allocate additional space to tablespace and reformat.

See "Collection Is Too Large".  

Format gets insufficient privilege error.  

See "Could Not View Oracle Trace Formatted Data".  

Examining Collection Data  

Collection contains no data.  

Oracle Trace interface to database is incorrectly configured or there are too many collections running in parallel.

See "Database Configuration".

See "Collection Is Empty".  

SQL statement not captured in collection.  

See "Missing SQL Statement from Collection".  

Wait times were not collected (for ALL event set).  

See "Wait Times Were Not Collected".  

Collection has additional data but Data Viewer summaries are unchanged.  

See "Additional Formatted Data Is Missing from Data Viewer".  

Data Viewer gets errors computing statistics.  

See "Need to Restore Formatted Data".  

Data Viewer performance is poor.  

See "Poor Performance".  

Server Environment

If you suspect a server environment problem, verify:

Oracle Enterprise Manager Configuration

Problems covered in this section are also known as client environment problems. Some of the symptoms of a configuration problem are: nodes and databases have not been discovered or refreshed, user preferences appear to be invalid, and jobs are not running in the Oracle Enterprise Manager Job system.

Try the following:

Network Configuration

Some of the symptoms of a network configuration problem are: the network times out, error messages stating the system could not be found or the service name could not be resolved.

Try the following:

Oracle Intelligent Agent (UNIX Specific)

Symptoms of an agent configuration problem are error messages stating the agent is not working or that the agent is not found. This section offers a few suggestions. Refer to the Oracle Enterprise Manager Configuration Guide for a more in-depth explanation of the Oracle Intelligent Agent.

Verify:

Oracle Intelligent Agent (NT Specific)

Symptoms of an agent configuration problem are error messages stating the agent is not working or that the agent is not found.

Verify that the agent is up and running. Select Start=>Settings=>Control Panel from the Task bar. Double-click on Services. Start the agent if it is not started.

Also, examine the NT Event log for individual applications. This log may provide additional information to help solve the problem.

Database Configuration

The symptom is that you scheduled a collection but no data is in the collection or there was an error formatting the data. Do the following.

Oracle Trace Configuration

If you suspect an Oracle Trace configuration problem:

Data Viewer Problems

The following section deals with problems specific to Data Viewer.

Could Not View Oracle Trace Formatted Data

To view Oracle Trace formatted data using the Data Viewer, a user account needs the following system privileges:

CREATE SESSION
CREATE SEQUENCE
CREATE TABLE
CREATE PROCEDURE
CREATE ANY INDEX
EXECUTE ANY PROCEDURE
DELETE ANY TABLE
DROP ANY INDEX
DROP ANY SEQUENCE
UNLIMITED TABLESPACE

Need to Restore Formatted Data

Data Viewer adds statistical information to your formatted data. To restore your formatted data to the exact state it was in prior to running Data Viewer, run the ORACLE_HOME\Sysman\Admin\TdvDrop.sql script. Reasons for restoring data include:

Wait Times Were Not Collected

Wait times are collected only if the INIT<sid>.ORA parameter, TIMED_STATISTICS, is set to TRUE. When you change this database parameter, you must stop and restart the database for the change to take effect.

Additional Formatted Data Is Missing from Data Viewer

The first time Data Viewer views a collection, you can compute SQL statistics for all queries currently in the collection. Data Viewer does not detect new data added to a collection by a partial format while Data Viewer is viewing that collection. If you choose to partially format your collected data, you can force Data Viewer to recompute statistics using both existing and newly collected data by choosing Options=>Recompute Statistics.

Missing SQL Statement from Collection

If an expected SQL statement does not appear to be in your collection, it may be because the Oracle Trace auto-format function does not flush the collection buffer until the next time the database is accessed after the collection was stopped. This may result in a small amount of event data not reaching the collection file.

Collection Is Too Large

There may be times when a collection is too large. Starting with Oracle Trace release 1.5.5 and Oracle Server release 8.0.4, you can collect data for specific users and specific Wait event types to minimize the size of the collection. Because the server is almost always waiting for a latch, lock, or resource, Wait event data for a brief collection can be quite extensive.

The Oracle Trace Collection Wizard walks you through limiting the collected data by individual users.

Poor Performance

If multiple collections exist in one set of user tables, computing statistics and subsequent selects may take longer than necessary. Placing a large collection in a new database user account will improve performance.

Table or View Does Not Exist (or No Data in Collection)

When a record is not written to the EPC_FACILITY_REGISTRATION table, the user may see an error like the following:

XP-21016: A database error has occurred:
SELECT DISTINCT FACILITY_NUMBER, FACILITY_VERSION, VENDOR 
FROM EPC_FACILITY_REGISTRATION WHERE COLLECTION_ID - :1
ORA-00942: table or view does not exist

Removing the 'Filtering by User' option on collections targeting Oracle Server release 8.0.4 databases will correct this problem for future collections.

Manually adding an EPC_FACILITY_REGISTRATION record for the collection allows Trace Data Viewer to see that collection's formatted data. For example, insert EPC_FACILITY_REGISTRATION record with the following values:

Collection_ID:    123       [Look in formatted data's EPC_COLLECTION table
                             for the collection_id column value that matches
                             your collection_name]
Vendor:           192216243 [Hard code this value]
Facility_number:  5         [Hard code this value]
Facility_version: '8.0'     [or '7.3' for a collection against a 7.3 database
                             or '8.1' for a collection against an 8.1 database]

Oracle Trace Manager Problems

The following section deals with problems specific to Oracle Trace Manager.

Failure Connecting to Show User List

If the user name and password you use to connect to the target collection database are correct, the problem may be that the service name used for connection is not the same name as your service name for the target collection database.

The service name is set to the service name as it is known to the Oracle Enterprise Manager console. The console gets the service name of discovered databases from the agent.

If the service name does not match the service name in your tnsnames.ora file, you will not be able to connect to the database when you click the Show User List button.

Edit your tnsnames.ora file and add a service name that matches the service name known to the Oracle Enterprise Manager console.

Format of Collection Failed

There are a number of reasons why this can occur.

Collection Is Empty

In Oracle8 databases, the ORACLE_TRACE_ENABLE parameter in the INITsid.ORA file on the server must be set to TRUE before the database is started. (In previous versions of Oracle Server, the ORACLE_TRACE_ENABLE parameter was set to FALSE.) You can also see this problem if there are too many collections running concurrently.

Refer to "Database Configuration" for additional information.

Oracle Trace Could Not Access Memory

On Windows NT systems, if you are running Oracle Trace collections and an error occurs indicating Oracle Trace could not access memory, the collect.dat file has become full. You must create a new .dat file by running the otrccref.exe image located in the $ORACLE_HOME/bin directory. However, database services must be shutdown to release the collect.dat file for the otrccref script to be able to create the new collect.dat file. You can also increase the number of collect.dat records above the default of 36 records (for example, otrccref -c50).

Isolating an Oracle Trace Problem

A good approach in isolating a problem is to perform tests on each component of Oracle Trace. The components are:

There are two Oracle Trace mechanisms that are valuable when troubleshooting: Oracle Trace logging window (see "Oracle Trace Manager Logging") and EPC_ERROR.LOG file (see "EPC_ERROR.LOG File").

Isolating a Problem in Oracle Trace Manager

You can test Oracle Trace Manager to determine if the problem is within the graphical user interface. Turn on Oracle Trace logging to see the communication within Oracle Trace Manager.

Oracle Trace Manager performs the following:

  1. Takes input from the user.

  2. Packages the information from the user into a temporary input parameters file. Oracle Trace Manager uses the Oracle Enterprise Manager Job system to schedule specified tasks. Within the Oracle Intelligent Agent, the otrcjob.tcl script then runs the job to be performed on the database server.

    The otrcjob.tcl script is a general purpose tcl script. It manages the other tcl scripts by taking input parameters plus those supplied by the temporary parameter files and running one of the other task specific tcl scripts.

    Each of the other tcl scripts is used to send the information required by the CLI images to perform the specific task against the database: start, stop, delete, or format a collection.

  3. The jobs submitted run the CLI images to start and stop collections, format the collection data, and delete the collection.

  4. The jobs manage the return of the information from the CLI to Oracle Trace Manager.

To check and see if the communications is set up correctly, you can run the Oracle Enterprise Manager Job system independently. You may also want to ping the server from the client and ping the client from the server.

Oracle Enterprise Manager Job System

You can use the Oracle Enterprise Manager Job system to test if the communication between Oracle Management Server and the Oracle Intelligent Agent is working. For step by step instructions, see "Oracle Enterprise Manager Configuration".

Formatter Tables

If you format a collection, Oracle Trace will format the data into your repository database and schema by default. The format operation requires repository tables to store collection information.

You can check that the formatter tables have been created.

You can query the database and look for the tables "EPC_COLLECTION". The tables that start with "EPC_CLI" are the repository tables. All the other tables that start with "EPC_" are the formatter tables.

An easy way to find the formatter tables is to use Oracle Enterprise Manager Schema Manager to graphically see if the formatter tables are present.

Oracle Server releases 7.3.4 and 8.0.4 and later automatically create the formatter tables. Prior to Oracle Server releases 7.3.4 and 8.0.4, you must run the otrcfmtc.sql script from Oracle Server Manager or Oracle SQL*Plus Worksheet as the user who will be formatting the data. To ensure version compatibility, use the otrcfmtc.sql script located in the ORACLE_HOME of the destination server.

The otrcfmtc.sql script is located in the $ORACLE_HOME/otracenn/admin directory (where nn represents the version of Oracle Trace).

Formatting error might be due to one of the following causes:

  1. The user did not run the script to create the formatter tables (valid for releases of Oracle Server prior to 7.3.4 and 8.0.4).

  2. The formatter tables were not created by the same user ID that was used when the collection was created (valid for releases of Oracle Server prior to 7.3.4 and 8.0.4).

  3. There is a version mismatch. If the user formats to a given schema with an Oracle Server release 8.0.4 formatter, then later tries to format to the same schema using an older formatter, for example Oracle Server release 7.3.x, an error occurs. For additional information see "New otrcfmt Image for Oracle Server Releases 7.3.4 and 8.0.4".

Isolating a Problem in Oracle Trace Collection Services

Here are a few suggestions to help you isolate problems in the Oracle Trace Collection Services.

Oracle Trace Command-Line Interface

Oracle Intelligent Agent uses the command-line interface to access the Oracle Trace Collection Services. You can run the CLI to determine if the Oracle Trace Collection Services are functioning properly.

The CLI is located on the same server as the database that you are running the collection against. If you have multiple ORACLE_HOMEs, you could have multiple CLIs, that is, one CLI per ORACLE_HOME. Verify that your path is pointing to the correct CLI.

To test the CLI:

  1. Run the CLI directly on the server node to test if the collection services are working properly.

    1. CLI needs to run from a privileged account, for example, the Oracle operating system user account.

    2. The Oracle Home and SID environmental variables must be set properly.

      To check settings on UNIX:

      printenv ORACLE_HOME
      printenv ORACLE_SID
      
      

      To set settings on UNIX:

      setenv ORACLE_HOME <path>
      setenv ORACLE_SID <sid>
      
      

      There should be one CLI per ORACLE_HOME. For example, if you have two Oracle Server release 7.3.3 instances sharing the same ORACLE_HOME, there should be only one CLI.

  2. Verify that the CLI release matches the database server release.

    The Oracle Trace Collection Services files may be overwritten on NT by other product installations. If this occurs, your Oracle Trace Collection Services files will no longer match the version required by your Oracle Server database and you may receive a memory mapping error.

    On the server node, type the following command on the operating system command line:

    $ORACLE_HOME/bin/otrccol version
    
    

    See Table C-2 for the possible results. If the versions do not match, call Oracle Support for additional assistance.

  3. Verify if the collection name has not already been used before you start the collection. Look in the .cdf and .dat directories $ORACLE_HOME\otracenn\admin on NT ($ORACLE_HOME/otrace/admin on UNIX).

  4. Prepare your input file as follows:

    <collection_name>.inp
    
    col_name= col_name (no spaces before equal sign and 1 space after equal 
    sign)
    dat_file= col_name.dat
    cdf_file= col_name.cdf
    fdf_file= oraclee.fdf (whatever .fdf file you wish to use)
    regid=1 192216243 0 0 5 <your_service_name> [for Oracle8 use <sid>]
    resubmit= 0 (1 only if resubmission)
    
    
  5. If you want to generate database activity for this collection, connect to the database.

    • For Oracle Server release 7.3.x, connect to the service before you create your collection.

    • For Oracle Server release 8.0, you can connect to the database anytime and the processes will be registered.

  6. To test the entire CLI process, start a collection, verify the collection is running, and stop the collection. For example:

    1. To start a collection:

      otrccol start <job_number> <collection_name.inp> (see step 4 
      where you can make up your own input parameter file)
      
      

      You should see the response "collection started".

      A .dat file and a .cdf file will be created in one of the following directories: $ORACLE_HOME/otrace/admin/cdf or the directory specified by the ORACLE_TRACE_COLLECTION_PATH parameter in your init<sid>.ora file.

    2. Verify that the collection was created.

      otrccol check <collection_name>
      
      

      The collection should show as active.

    3. To stop a collection:

      otrccol stop <job_number> <collection_name.inp>
      
      

      After you run the stop command your collection will not show as active.

    If there are any errors, the EPC_ERROR.LOG file will be written to the same directory from which you run the otrccol command.

  7. Test that the format works properly. Choose a schema in a database with enough room to hold the data.

    1. Verify that the formatter tables have been created by querying the schema to see if there are tables prefixed with `EPC_'. The Oracle Trace repository tables are prefixed with `EPC_CLI' and the formatter tables are prefixed with 'EPC_'. You can also use Oracle Schema Manager to look at the tables.

    2. Attempt to format a collection using the command-line interface.

      otrccol format <format_input_file>
      
      

      The format_input_file contains the following input parameters:

      username= <db username>
      password= <db pw>
      service= <db service name>
      cdf_file= <collection_name>.cdf
      full_format= <0/1>
      
      

      Full format value of 1 formats all the data in the data file, 0 formats only the data that has not previously been formatted.

Stored Procedures

If the attempt to collect Oracle Trace data for an Oracle7 database results in the message "Error starting/stopping Oracle7 database collection," this may be due to missing database stored procedures that Oracle Trace uses to start and stop Oracle7 collections.

To verify that the stored procedures are present:

Prior to Oracle Server release 8.0.3, Oracle Trace required that stored procedures be installed on the database. These SQL scripts may be automatically run during database installation depending on the platform-specific installation procedures. If they are not executed during database installation, you must run these scripts manually. You can add these stored procedures to the database by running the otrcsvr.sql script from $ORACLE_HOME\otracenn\admin on NT ($ORACLE_HOME/otrace/admin on UNIX) from a privileged database account (SYS or INTERNAL). To run the script, set the default to the path were the script is located. This script runs other scripts that do not have the path specified. These other scripts fail if you are not in the directory where these scripts will run.

Oracle Trace Manager Logging

There are two methods by which to capture activity taking place in the Oracle Trace Manager: logging window (/l option) and log file (/o option). Run Oracle Trace Manager with the /l option, the /o option, or both options activated. To activate the options, do the following:

  1. Run the Oracle Enterprise Manager console.

  2. From the Start menu, choose Run.

  3. Assuming your ORACLE_HOME is C:\ORANT, in the Open field, type:

    C:\ORANT\BIN\EPC.EXE /l /o=<filename> [Do not leave any spaces 
    between the equal sign and the filename.]
    
    
  4. Click OK.

This displays the Oracle Trace Log window, which displays in-depth information about Oracle Trace Manager client/server processing. This information includes:

With the /o option activated, you automatically have a file copy of the information displayed in the logging window.

EPC_ERROR.LOG File

The EPC_ERROR.LOG file provides information about the collection processing, specifically the Oracle Trace Collection Services errors.

The EPC_ERROR.LOG file is created in the current default directory of the Oracle Intelligent Agent when it runs the Oracle Trace Collection Services otrccol image.

Depending if you are running Oracle Trace from the Oracle Trace Manager or the command-line interface, the EPC_ERROR.LOG file can be located in one of the following server locations:

To find the file on UNIX, do the following:

% cd $ORACLE_HOME
% find . -name EPC_ERROR.LOG -print


Note:

On UNIX the EPC_ERROR.LOG file name is case sensitive and is in uppercase.  


For general information about causes and actions for most Oracle Trace messages, see the Oracle Enterprise Manager Messages Manual.

Information Needed When Reporting a Problem

If you have tried all the previously described suggestions and Oracle Trace is still not working, please call your local Oracle World Wide Support Center. When reporting a problem, have the following information available:




Prev

Next
Oracle
Copyright © 1999 Oracle Corporation.

All Rights Reserved.

Library

Product

Contents

Index