Alert Logs and Trace Files:
All Oracle background process have their own trace files where information about errors are dumped to when detected. Alert logs also contain information about database errors, with less detail and normally point towards specific trace file. Message in alert log include:
- Init parameter with non-default values or other notations.
- all errors: internal ORA-600, block corruption ORA-1578 and deadlock ORA-60
- Admin DDL CREATE, ALTER, and DROP and startup and shutdown.
Alert logs are maintained in both XML and plain text. The ADRCI utility is used to view XML alert logs. Both Alert and trace files are stored under the Automatic Diagnostic Repository directory structure. The init parameter MAX_DUMP_FILE_SIZE limits the size of trace files to a set number of OS blocks. You cannot limit size of alert logs, but it is a good practice to periodically rename the alert file to reduce file size oracle is using. The database instance will automatically create a new alert log with appropriate name and this renaming process can be done with the database online.
Statistics:
Statistics are generated by the Oracle 12c database to help increase level of performance and to all the optimizer to decide on the best execution plans of SQL statements. If the SQL_TRACE init parameter is set to TRUE, performance statistics will be generated for SQL statements. SQL tracing can be set at session level by ‘ALTER SESSION SET SQL_TRACE’ command. Trace files are written to Automatic Diagnostic Repository directory structure. The DBMS_SESSION and DBMS_MONITOR packages can be used to control SQL tracing for a session.
Adaptive Thresholds:
You can monitor database continuously with adaptive thresholds. By setting warning and critical alerts for system metrics. This can be done using moving window metrics. Two types of adaptive thresholds:
Percentage of maximum – Defined as the max of data/resource in moving window. like 80% of observed.
Significance level – Defined to a unusual value of threshold, set to one of the following values
- High (.95)
- Very High (.99)
- Severe (.999)
- Extreme (.9999)
Larry Catt
OCP