Systemstate dump when connection to the instance is not possible (文档 ID 359536.1)

APPLIES TO:

Oracle Server - Enterprise Edition - Version: 9.2.0.1 to 10.2.0.2 - Release: 9.2 to 10.2
Linux x86
HP-UX PA-RISC (64-bit)
IBM AIX on POWER Systems (64-bit)
Oracle Solaris on SPARC (64-bit)
HP Tru64 UNIX
***Checked for relevance on 30-Sep-2010*** 
Oracle Real Application Clusters

GOAL

The goal of this document is to collect vital information that may help Support understand the cause of the hang. Generally these hangs do not allow a new connection else running racdiag Note:135714.1

SOLUTION

There are several ways of getting more information when connection to an instance is not possible by sqlplus. It is useful to collect as much information about a hang before clearing the instance.

1.)  Using OS debuggers like dbx or gdb. 
For example:

 

$ps -ef |grep $ORACLE_SID                                    ## Use PID of any User Process instead of BG Process
$gdb $ORACLE_HOME/bin/oracle
print ksudss(10)

The systemstate dump will be in the bdump or udump depending on the PID chosen

 

2.) Using the new 10.1 sqlplus -prelim option.  
For example:

 

export ORACLE_SID=PROD                                 ## Replace PROD with the SID you want to trace
sqlplus -prelim / as sysdba
oradebug setmypid
oradebug unlimit;
oradebug dump systemstate 10

 

3.) Finally if either option (1) or (2) is not doable, please remember to take stacks of all the Oracle Background process using pstack or gdb

For example:

 

script stack.log
pstack
pstack

 

4.) Finally you may also want to collect some truss, tusc or strace of sqlplus


Note:  The recommended systemstate level for 10g is 266

你可能感兴趣的:(oracle基础)