Log Information in Oracle Analytics Presentation Services
This section describes logging specifically in Presentation Services .
Topics include:
See Understand Diagnostic Log Files and Log Configuration Files.
Use the Presentation Services Logging Facility
You can troubleshoot issues and errors using the Presentation Services logs.
By default, Presentation Services is configured to log all error events and informational and warning events of sufficient importance. An example of an important informational event is a server starting up or a server shutting down. Log files are named sawlogxx.log, where the xx is replaced by an incremented number.
To debug specific issues that a user might be encountering, the logging level can be increased to log more information than the default configuration. For example, while debugging a particular Presentation Services connectivity issue, you can increase the maximum logging on the saw.odbc log source only. This adds detailed logging for that component, without cluttering the log with detailed logging from other events. All Presentation Services configuration information is loaded from the instanceconfig.xml file.
Caution:
Because logging affects performance, don't increase the logging on a production implementation, except to diagnose specific issues.Set the Logging Levels for Presentation Services
You use options on the Administration page in Presentation Services to affect logging levels.
Structure for the Presentation Services Configuration File
The structure of the Presentation Services configuration file allows system output to be presented properly.
The structure of the configuration file is shown in the following example. The cardinality of each node is shown in brackets.
Example 8-3 Structure of Log Section in instanceconfig.xml File
Logging [1..1] Writers [0..1] Writer [0..1] WriterClassGroups [0..1] Filters [0..1] FilterRecord [0..n]
An example of an instanceconfig.xml file that has four writers is shown below.
Example 8-4 instanceconfig.xml File with Four Writers
<?xml version="1.0" ?> <Server> . . . . . . . <Logging> <Writers> <Writer implementation="FileLogWriter" name="Global File Logger" writerClassId="1" dir="{%ORACLE_BIPS_INSTANCE_LOGDIR%}" filePrefix="sawlog" maxFileSizeKb="10000" filesN="10" fmtName="ODL-Text" ODLLogFilePath="{%ORACLE_BIPS_INSTANCE_LOGDIR%}/diagnostic.log"/> <Writer implementation="CoutWriter" name="Global Output Logger" writerClassId="2" /> <Writer implementation="EventLogWriter" name="Event Logger" writerClassId="3" /> <Writer implementation="CrashWriter" name="CrashWriter" writerClassId="4" /> </Writers> <WriterClassGroups> <WriterClassGroup name="All">1,2,3,4</WriterClassGroup> <WriterClassGroup name="File">1</WriterClassGroup> <WriterClassGroup name="Console">2</WriterClassGroup> <WriterClassGroup name="EventLog">3</WriterClassGroup> <WriterClassGroup name="Crash">4</WriterClassGroup> </WriterClassGroups> <Filters> <FilterRecord writerClassGroup="Console" path = "saw" information="1" warning="31" error="31" trace="0" incident_error="32" /> <FilterRecord writerClassGroup="File" path = "saw" information="1" warning="31" error="31" trace="0" incident_error="32" /> <FilterRecord writerClassGroup="File" path="saw.mktgsqlsubsystem.joblog" information="1" warning="2" error="31" trace="0" incident_error="32"/> <FilterRecord writerClassGroup="File" path="saw.httpserver.request" information="16" warning="32" error="32" trace="0" incident_error="32"/> <FilterRecord writerClassGroup="File" path="saw.httpserver.response" information="16" warning="32" error="32" trace="0" incident_error="32"/> </Filters> </Logging> </Server>
The following table contains a description of each node in the configuration hierarchy.
Element | Attribute | Description |
---|---|---|
Writers |
None |
Contains writers configuration. This configuration is loaded on startup. |
Writer |
None |
Configures a writer. |
Writer |
disableCentralControl |
(Optional) Determines that this entry isn't updated by Fusion Middleware Control. Default value is true. |
Writer |
implementation |
The following implementations are defined:
|
Writer |
name |
Unique name for the writer. |
Writer |
writerClassId |
Specifies an integer number in the range 1 through 10. This number is used by filters to allow or prohibit logging. Each distinct writer must have a unique value, which is used later for filter configuration. Different writers might have the same class ID, but if they do, those writers can't be distinguished by filters. |
Writer |
fmtName |
(Optional) Specifies the format of logged messages. Valid values are:
If you don't set this attribute, then logged messages are displayed in the default format which for file log writers is 10g style and for console is ODL-TEXT. See Examples of the Formats of Logged Messages for examples. |
Writer (FileLogWriter specific attribute) |
dir |
Specifies the directory where log files are created. |
Writer (FileLogWriter specific attribute) |
ODLLogFilePath |
Specifies the file that Fusion Middleware Control displays in the Log Viewer. |
Writer (FileLogWriter specific attribute) |
maxFileSizeKb |
Specifies the maximum size of the logging file in kilobytes. When the file size limit is reached, the file is closed and a new logging file is created. |
Writer (FileLogWriter specific attribute) |
filePrefix |
Specifies the prefix for log files. |
Writer (FileLogWriter specific attribute) |
filesN |
Specifies the maximum number of logging files. When this number is exceeded, the first file is deleted and re-created again. Then the logger starts to write to the beginning of the first file. |
Writer (EventLogWriter specific attribute) |
winSource |
Specifies the event log source for logged events. |
Writer (CrashWriter specific attribute) |
file |
Specifies the dump file path. On Windows, a dump file is created in |
Writer (CrashWriter specific attribute) |
line |
Dump file line number. |
WriterClassGroups |
None |
Contains the definition for writer classes. A writer class is a group of writer class IDs. |
WriterClassGroup (Contains [as child text] a comma-delimited list of class IDs.) |
name |
Specifies the name of the WriterClassGroup. |
Filters |
None |
Contains filter configuration. |
FilterRecord |
writerClassGroup |
Specifies the group of writers to which this record is applied. WriterClassGroup is likely defined previously in the WriterClassGroups section. |
FilterRecord |
disableCentralControl |
(Optional) Determines that this entry isn't updated by Fusion Middleware Control. Default value is true. |
FilterRecord |
path |
Specifies the log source path. To enable the logging of SOAP information, enter the following value: saw.httpserver.request.soaprequestThe current filter record is applied to the software component that's identified by that path and all its subcomponents. |
FilterRecord |
information |
Contains an integer that specifies the severity of the corresponding message type. Only messages with a severity index less than the provided number are logged. |
FilterRecord |
warning |
Contains an integer that specifies the severity of the corresponding message type. Only messages with a severity index less than the provided number are logged. |
FilterRecord |
error |
Contains an integer that specifies the severity of the corresponding message type. Only messages with a severity index less than the provided number are logged. |
FilterRecord |
trace |
Contains an integer that specifies the severity of the corresponding message type. Only messages with a severity index less than the provided number are logged. |
FilterRecord |
incident_error |
Contains an integer that specifies the severity of the corresponding message type. Only messages with a severity index less than the provided number are logged. |
Examples of the Formats of Logged Messages
The fmtName attribute of the Writer element formats logged messages in one of three formats: default (10g style), ODL-TEXT, and ODL-XML.
The following example shows the default format.
Example 8-5 Default Format
The default format generates messages with identifying headings, such as:
Type: Information
Severity: 30
Time: Wed Jul 26 11:22:20 2006
File: project\sawserver\sawserver.cpp
Line: 399
Properties: ThreadID-2552
Location:
saw.sawserver
saw.sawserver.initializesawserver
saw.sawserver
Oracle BI Presentation Services has started successfully.
The following example shows the ODL-TEXT format.
Example 8-6 ODL-TEXT Format
The short format generates messages in a shortened form without identifying headings, such as:
[timestamp] [component id] [messagetype:level] [message-id] [module id] ([field-name: field-value])* message-text [[
supplemental-detail
]]
[2010-05-27T10:51:20.000-07:00] [OBIPS] [NOTIFICATION:1] [] [saw.sawserver] [ecid: 1243446680218334471555761] [tid: 2552] Oracle BI Presentation Services (OBIPS) 11.1.1.2 (Build 0) are starting up.[[
File:sawserver.cpp
Line:432
Location:
saw.sawserver
saw.sawserver.initializesawserver
saw.sawserver
ecid: 1243446680218334471555761
]]
The following example shows the ODL-XML format.
Example 8-7 ODL-XML Format
The xml format generates messages in XML format, such as:
<msg time="2010-05-08T18:41:05.000+00:00"
comp_id="OBIPS" type="NOTIFICATION" level="1" msg_id=""
module="saw.sawserver" ecid="124180446517874242628761" tid="127c">
<txt> Oracle BI Presentation Services has started successfully</txt>
<suppl_detail />
</msg>
Presentation Services Message Structure
Each message that is logged by Publisher has several components, as described below.
Message Component | Description |
---|---|
Message Text |
The text of the log message to the user. |
Message Type |
One of five types: information, warning, error, incident_error or trace. |
Severity |
The severity is represented as a positive integer. The lower the value, the more important the message. A message with severity of 0 is the most important type of message, whereas a message with a severity of 32 isn't important. |
Message Properties |
Properties indicate other kinds of information. The kind varies among messages and might include user name, the IP address of the client browser, the thread ID, and so on. |
Presentation Services Log Filters
FilterRecords customize logging details. Use FilterRecords to specify the implementation (output type) and logging levels for categories of web logs: Incident Error, Error, Trace, Warnings, and Information.
In the following example, the first two FilterRecords contain the following string:
path="saw"
This string logs the informational events at level 1, the error messages at level 31, and so on:
<FilterRecord writerClassGroup="Console" path="saw" information="1" warning="31" error="31" trace="0" incident_error="32" />
<FilterRecord writerClassGroup="File" path="saw" information="1" warning="31" error="31" trace="0" incident_error="32" />
<FilterRecord writerClassGroup="File" path="saw.mktgsqlsubsystem.joblog" information="1" warning="2" error="31" trace="0" incident_error="32"/>
This high-level path applies to every event.
You can customize FilterRecords by adding new FilterRecords, such as the third one shown in the preceding example, with finer-grain specification of log levels for events of various types. In this example, information is being logged to a disk file from saw.mktgsqlsubsystem.log, which generates Marketing job events.
You can disable logging of job details by changing the information level from 1 to 0, as shown in the following example, or by commenting out the lines:
<FilterRecord writerClassGroup="Console" path="saw" information="1" warning="31" error="31" trace="0" incident_error="32" />
<FilterRecord writerClassGroup="File" path="saw" information="1" warning="31" error="31" trace="0" incident_error="32" />
<FilterRecord writerClassGroup="File" path="saw.mktgsqlsubsystem.joblog" information="1" warning="2" error="31" trace="0" incident_error="32"/>
Diagnose Issues with Agents
This section contains the following topics:
Debug Agents Using Fusion Middleware Control
Agent error and debug log entries are written to the main scheduler log file nqscheduler.log
, and are visible in Log Viewer using Fusion Middleware
Control.
See Use Fusion Middleware Control to View Log Information, Error Messages, and Alerts.
An agent log entry includes key agent events, and provides information on a single trace line. For example:
Agent Chain Completed. Status: Completed, Agent ID: /users/weblogic/ChainedAgent, UserID: weblogic, OBIPS: example.com:0:9710, Job/Instance ID: 123/4567.
The table below details agent event logging, and associated trace types and levels.
Event | State | Message Type:Level |
---|---|---|
Agent Chain Started |
Running |
TRACE:1 |
Agent Chain Started |
ReRunning |
NOTIFICATION:1 |
Agent Chain Complete |
Failed |
ERROR:1 |
Agent Chain Complete |
Timed Out |
ERROR:1 |
Agent Chain Complete |
Timed Out |
WARNING:1 |
Agent Chain Complete |
Warning |
WARNING:1 |
Agent Chain Complete |
Cancelled |
NOTIFICATION:1 |
Agent Chain Complete |
Try Again |
NOTIFICATION:1 |
Agent Chain Complete |
Completed |
TRACE:1 |
Agent Started |
N/A |
TRACE:1 |
Agent Finished |
N/A |
TRACE:1 |
You can determine the log output detail written to the nqscheduler.log file by setting the level in Fusion Middleware Control. See Configure Log File Rotation Policy and Specify Log Levels. You can also filter log entries using ECID to find information specific to a particular agent chain.
Debug Agents Manually
If an agent fails to run fully or if debugging is turned on in Oracle BI Scheduler, then a log file is generated for the agent.
You manually enable debugging by setting the Trace
element to the value of 32
in the Oracle BI Scheduler schedulerconfig.xml file, or by assigning the Fusion Middleware Control setting, LogLevel to 'Finest'.
The schedulerconfig.xml file is located at:
<domain_home>/config/fmwconfig/biconfig/OBISCH
Note:
You don't need to restart the component. Set the value back to the default after debugging completes.See What Are Diagnostic Log Configuration Files and Where Are They Located?
The location for agent log files is also specified in the instanceconfig.xml file for the Oracle BI Scheduler (see Agent Scheduler Configuration Settings.) The default location for log files is the Log directory in the installation directory on the computer where the Oracle BI Scheduler is installed.
The log file name has the following format:
Agent-JobID-InstanceID.xxx
In this file name:
-
Agent is the prefix for all agent log files.
-
JobID is the Oracle BI Scheduler job identifier for the agent.
-
InstanceID is the Oracle BI Scheduler instance identifier for the agent.
-
xxx is the file extension:
-
.err for agent error log files.
-
.log for debug log files.
-
The agent error and debug log files are written as separate files for each agent instance that fails to run. You can use a text editor to view the files. Entries are generally self-explanatory.
The presence of an error log doesn't necessarily mean that an agent failed completely. For example, suppose an agent delivers content to multiple email addresses. If some addresses are invalid or the mail server is down, then an error log is generated for the agent.