mardi 9 août 2011

Oracle : adrci - How to display alerts...

To display trace and alerts from a 11g database use the adrci tools in $ORACLE_HOME/bin
>adrci
and after ask the alert log
adrci> show alert -tail -f
and other way to display alerts under adrci could be
>adrci exec="show alert -tail -f"
To display alerts generated by the listener you can use also the adrci tool:
>adrci
adrci>set homepath diag/tnslsnr
adrci>show alert -tail 200 -f

To display incident of the orcl database
$>adrci
adrci> set homepath diag/rdbms/orcl/orcl
adrci> show incident

note: To display adrci policy :
adrci> show control

note :To package an incident see use of ips command with adrci tool.

note : To visualize the report of health monitor task use
adrci>show hm_run
----------------------------------------------------------                                                                                                    RUN_ID                       11081
RUN_NAME                     HM_RUN_11081
CHECK_NAME                   Cross Check
NAME_ID                      2
MODE                         2
START_TIME                   2007-04-13 03:20:31.161396 -07:00
RESUME_TIME
END_TIME                     2007-04-13 03:20:37.903984 -07:00
MODIFIED_TIME                2007-04-17 01:16:37.106344 -07:00
TIMEOUT                      0
FLAGS                        0
STATUS                       5
SRC_INCIDENT_ID              0
NUM_INCIDENTS                0
ERR_NUMBER                   0
REPORT_FILE

adrci> create report hm_run HM_RUN_11081
adrci> show report hm_run HM_RUN_11081