C.1 tfactl analyze
Use the tfactl analyze
command to obtain analysis of your system by parsing the database, Oracle Automatic Storage Management (Oracle ASM), and Oracle Grid Infrastructure alert logs, system message logs, OSWatcher Top, and OSWatcher Slabinfo files.
Filter the output of the command by component, error type, and time.
With the tfactl analyze
command, you can choose from the following types of log file analysis:
-
Show the most common messages within the logs: This analysis provides a quick indication of where larger issues are occurring. Oracle Trace File Analyzer takes important messages out of the alert logs and strips the extraneous information from the log messages, organizes the most commonly occurring messages, and displays them in the order from most common to least common. By default, Oracle Trace File Analyzer analyzes error messages, but you can specify a particular type of message for analysis.
-
Search for text within log messages: This is similar to using the
grep
utility to search, only faster because Oracle Trace File Analyzer checks the time of each message and only shows those matching the last x number of minutes or any interval of time. -
Analyze the Oracle OSWatcher log statistics: Oracle Trace File Analyzer reads the various statistics available in the
OSWatcher
log files and provides detailed analysis showing first, highest, lowest, average, and the last three readings of each statistic. Choose any interval down to a specific minute or second. Oracle Trace File Analyzer optionally provides the original data from theOSWatcher
logs for each value reported on (data point).
Syntax
tfactl analyze [-search "pattern"]
[-comp db|asm|crs|acfs|os|osw|oswslabinfo|oratop|all]
[-type error|warning|generic]
[-last n[h|d]]
[-from "MMM/DD/YYYY HH24:MI:SS"]
[-to "MMM/DD/YYYY HH24:MI:SS"]
[-for "MMM/DD/YYYY HH24:MI:SS"]
[-node all|local|n1,n2,...]
[-verbose]
[-o file]
[-examples]
Parameters
Table C-1 tfactl analyze Command Parameters
Parameter | Description |
---|---|
|
Searches for a pattern enclosed in double quotation marks ("") in system and alert logs within a specified time range. This parameter supports both case-sensitive and case-insensitive search in alert and system message files across the cluster within the specified filters. Default is case insensitive. If you do not specify the Oracle Trace File Analyzer displays message counts grouped by type
( |
|
Select which components you want Oracle Trace File Analyzer to analyze. Default is
When |
|
Select what type of messages Oracle Trace File Analyzer analyzes. Default is
|
|
Specify an amount of time, in hours or days, before current time that you want Oracle Trace File Analyzer to analyze. |
|
Specify a time interval, using the |
|
Specify a comma-separated list of host names. Use |
|
Displays verbose output. |
|
Specify a file where Oracle Trace File Analyzer writes the output instead of displaying on the screen. |
|
Specify this parameter to view |
-type Parameter Arguments
The tfactl analyze
command classifies all the messages into different categories when you specify the -type
parameter. The analysis component provides count of messages by the message type you configure and lists all unique messages grouped by count within specified filters. The message type patterns for each argument are listed in the following table.
Table C-2 tfactl analyze -type Parameter Arguments
Argument | Description |
---|---|
error |
Error message patterns for database and Oracle ASM alert logs:
Error message patterns for Oracle Grid Infrastructure alert logs:
|
warning |
Warning message patterns for database and Oracle ASM alert logs:
|
generic |
Any messages that do not match any of the preceding patterns. |
oratop options
-comp oratop
: -database dbname oratop options logon
Table C-3 tfactl analyze -comp oratop options
Argument | Description |
---|---|
|
Specify the name of the Oracle Database to run |
|
Default is Specify a different user using,
Connect Identifier:
|
Table C-4 oratop options
Argument | Description |
---|---|
|
Real-time (RT) wait events (section 3. Default is Cumulative.. |
|
FILE#:BLOCK#, section 4 lt is (EVENT/LATCH). |
|
Specify |
|
Specify the SQL mode (section 4). Default is process mode. |
|
Specify the Oracle Database service mode. Default is connect string. |
|
Specify the detailed format (132 columns). Default is standard (80 columns). |
|
Specify the batch mode. Default is text-based user interface. |
|
Specify the maximum number of iterations. |
|
Specify the interval delay in seconds. Default is 5 seconds. |
Examples
The following command examples demonstrate how to use Oracle Trace File Analyzer to search collected data:
-
$ tfactl analyze -search "error" -last 2d
Oracle Trace File Analyzer searches alert and system log files from the past two days for messages that contain the case-insensitive string "error".
-
$ tfactl analyze -comp os -for "Jul/01/2016 11" -search "."
Oracle Trace File Analyzer displays all system log messages for July 1, 2016 at 11 am.
-
$ tfactl analyze -search "/ORA-/c" -comp db -last 2d
Oracle Trace File Analyzer searches database alert logs for the case-sensitive string "ORA-" from the past two days.
The following command examples demonstrate how to use Oracle Trace File Analyzer to analyze collected data:
-
$ tfactl analyze -last 5h
Oracle Trace File Analyzer displays a summary of events collected from all alert logs and system messages from the past five hours.
-
$ tfactl analyze -comp os -last 1d
Oracle Trace File Analyzer displays a summary of events from system messages from the past day.
-
$ tfactl analyze -last 1h -type generic
Oracle Trace File Analyzer analyzes all generic messages from the last hour.
The following command examples demonstrate how to use Oracle Trace File Analyzer to
analyze OSWatcher
Top and Slabinfo:
-
$ tfactl analyze -comp osw -last 6h
Oracle Trace File Analyzer displays
OSWatcher
Top summary for the past six hours. -
$ tfactl analyze -comp oswslabinfo -from "2016-07-01" -to "2016-07-03"
Oracle Trace File Analyzer displays
OSWatcher
Slabinfo summary for specified time period.