11g單實例使用ASM監聽出現ORA-12537

問題描述:



linux平臺11.2.03的單實例。由於要做一些ASM的測試,在現有database的環境下安裝了GRID,並配置了ASM。調整了鑑聽,關閉了oracle下的監聽,啓動了grid的監聽。但是在客戶端連接時報錯如下:


SQL> conn erm/erm@qing
ERROR:
ORA-12537: TNS: 連接關閉


發現使用grid的用戶下的實例是可以連接的
SQL> conn sys/[email protected]:1521/+ASM as sysasm
已連接。


但是在oracle下的實例卻不能連接
SQL> conn sys/[email protected]:1521/qing as sysdba
ERROR:
ORA-12537: TNS: 連接關閉




警告: 您不再連接到 ORACLE。


解決辦法:

調整了半天,使終未能解決掉,最後從網上找到了解決辦法,參考了:[ID 1069517.1]。主要原因是監聽和database在不同的操作系統用戶下。需要一些互相訪問的權限,招MOS上的說明,一步步檢查。


最後我的實際問題與解決方法:
[oracle@OEL63 bin]$ pwd
/u01/oracle/product/11.2.0/dbhome_1/bin
[oracle@OEL63 bin]$ ll oracle
-rwxr-xr-x 1 oracle oinstall 232399083 Aug 22  2013 oracle
[oracle@OEL63 bin]$ chmod 6571 oracle
[oracle@OEL63 bin]$ ll oracle
-r-srws--x 1 oracle oinstall 232399083 Aug 22  2013 oracle


MOS [ID 1069517.1]資料:





ORA-12537 if Listener (including SCAN Listener) and Database are Owned by Different OS User [ID 1069517.1]




Symptoms
In environment where listener home (including SCAN listener which resides in Grid Infrastructure/ASM home) and database home are owned by different OS user, ORA-12537 could happen when connecting through listener, when creating database through DBCA, or when installing database software and creating a database in runInstaller. Job Role Separation is a typical example as SCAN and local grid home listener is owned differently than database.


Error detail
12537, 00000, "TNS:connection closed"
// *Cause: "End of file" condition has been reached; partner has disconnected.
// *Action: None needed; this is an information message.
Before the error is reported, connection could hang for a while, and a core file may also be generated.
Screen output:
SQL> conn system/xxx@OSES
ERROR:
ORA-12537: TNS:connection closed
OR
PRCR-1079 : Failed to start resource ora.db11.db
CRS-5011: Check of resource db11 failed: details at ..
CRS-2674: Start of ora.db11.db on racnode1 failed
ORA-12546: TNS:permission denied


listener_scann.log or listener.log
TNS-12518: TNS:listener could not hand off client connection
TNS-12546: TNS:permission denied
 TNS-12560: TNS:protocol adapter error
  TNS-00516: Permission denied
   Linux Error: 13: Permission denied
OR
TNS-12518: TNS:listener could not hand off client connection
TNS-12547: TNS:lost contact
 TNS-12560: TNS:protocol adapter error
  TNS-00517: Lost contact
   Linux Error: 32: Broken pipe


runInstaller error if installing
INFO: Starting Output Reader Threads for process /ocw/grid/bin/kfod
INFO: Parsing KFOD-00300: OCI error [-1] [OCI error] [ORA-12547: TNS:lost contact
INFO: Parsing ] [12547]
INFO: Parsing
INFO: The process /ocw/grid/bin/kfod exited with code 1
..
SEVERE: [FATAL] [INS-30502] No ASM disk group found.
   CAUSE: There were no disk groups managed by the ASM instance +ASM1.
 
Cause
1. Listener owner (including SCAN listener) can not access oracle binary in database home:
As listener owner:


$ ls -l $RDBMS_HOME/bin/oracle
ls: /home/oracle/app/oracle/product/11.2/db/bin/oracle: Permission denied


2. Oracle binary in database home has wrong permission:


ls -l $RDBMS_HOME/bin/oracle
-rwxr-x--x 1 oracle asmadmin 184286251 Aug  9 16:25 /home/oracle/app/oracle/product/11.2/db/bin/oracle
The permission "-rwxr-x--x" is wrong as it's missing suid bit, oracle binary should have permission of 6751:


-rwsr-s--x 1 oracle asmadmin 184286251 Aug  9 16:25 /home/oracle/app/oracle/product/11.2/db/bin/oracle
Note: If Job Role Separation is in place, the group will be <asmadmin>, otherwise it will be <oinstall>


3. File System for database home does not support setuid/suid or has nosetuid/nosuid set:


mount| grep <mount_point_of_ORACLE_HOME>
/home/oracle on /dev/dsk/diskoracle read/write/nosuid..
 
Solution
Solution is to make sure file system for database home has setuid/suid set, database binary($RDBMS_HOME/bin/oracle) has correct ownership and permission, and listener owner is able to access database oracle binary (as listener owner, "ls -l $RDBMS_HOME/bin/oracle" will tell)
If its Job Role Separation environment, please refer to the following document:
Oracle? Grid Infrastructure 
Installation Guide
11g Release 2 (11.2)
Oracle ASM Job Role Separation Option with SYSASM
 
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章