oracle 12C RAC 啟動報錯 ORA-00845

流浪的野狼發表於2014-11-30
oracle 12C RAC在安裝完後,啟動例項的時候一直報錯如下:
[grid@node01 ~]$ srvctl start database -d cloud -verbose
PRCR-1079 : Failed to start resource ora.cloud.db
CRS-5017: The resource action "ora.cloud.db start" encountered the following error: 
ORA-00845: MEMORY_TARGET not supported on this system
. For details refer to "(:CLSN00107:)" in "/oracle/app/12.0.1/grid/log/node01/agent/crsd/oraagent_oracle/oraagent_oracle.log".

CRS-5017: The resource action "ora.cloud.db start" encountered the following error: 
ORA-00845: MEMORY_TARGET not supported on this system       ----------關鍵問題,說明target值超過了某一個範圍無法調整。
. For details refer to "(:CLSN00107:)" in "/oracle/app/12.0.1/grid/log/node02/agent/crsd/oraagent_oracle/oraagent_oracle.log".

CRS-2674: Start of 'ora.cloud.db' on 'node01' failed  ----------兩個例項均啟動失敗
CRS-2674: Start of 'ora.cloud.db' on 'node02' failed
CRS-2632: There are no more servers to try to place resource 'ora.cloud.db' on that would satisfy its placement policy

檢視該報錯的官方解釋:
00845, 00000, "MEMORY_TARGET not supported on this system"
// *Cause: The MEMORY_TARGET parameter was not supported on this operating system or /dev/shm was not sized correctly on Linux.
// *Action: Refer to documentation for a list of supported operating systems. Or, size /dev/shm to be at least the SGA_MAX_SIZE on each Oracle instance running on the system.

Starting with Oracle Database 12c, the Automatic Memory Management feature requires more shared memory (/dev/shm)and file descriptors. The size of the shared memory should be at least the greater of MEMORY_MAX_TARGET and MEMORY_TARGET for each Oracle instance on the computer. If MEMORY_MAX_TARGET or MEMORY_TARGET is set to a non zero value, and an incorrect size is assigned to the shared memory, it will result in an ORA-00845 error at startup.

解決方法,因伺服器資源不多,同時memory_max_size=2G,暫且就將/dev/shm調整為4G:
[root@node01 ~]# vi /etc/fstab
/dev/VolGroup00/LogVol00 /                       ext3    defaults        1 1
LABEL=/boot             /boot                   ext3    defaults        1 2
tmpfs                   /dev/shm                tmpfs   defaults,size=4G        0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0
/dev/VolGroup00/LogVol01 swap                    swap    defaults        0 0


/dev/xvdc1 /oracle ext3 defaults 0 0
[root@node01 ~]# mount -o remount,size=4G /dev/shm
儲存後重新啟動RAC:
[grid@node01 ~]$ srvctl start database -d cloud -verbose
檢查資源情況,順便觀察下12C rac 資源與11g的差異:
[grid@node01 ~]$ crs_stat -t -v
Name           Type           R/RA   F/FT   Target    State     Host        
----------------------------------------------------------------------
ora.ARCH.dg    ora....up.type 0/5    0/     ONLINE    ONLINE    node01      
ora.DATA.dg    ora....up.type 0/5    0/     ONLINE    ONLINE    node01      
ora....ER.lsnr ora....er.type 0/5    0/     ONLINE    ONLINE    node01      
ora....N1.lsnr ora....er.type 0/5    0/0    ONLINE    ONLINE    node01      
ora.MGMTLSNR   ora....nr.type 0/0    0/0    ONLINE    ONLINE    node01      
ora.OCR.dg     ora....up.type 0/5    0/     ONLINE    ONLINE    node01      
ora.asm        ora.asm.type   0/5    0/     ONLINE    ONLINE    node01      
ora.cloud.db   ora....se.type 0/2    0/1    ONLINE    ONLINE    node01      
ora.cvu        ora.cvu.type   0/5    0/0    ONLINE    ONLINE    node01      
ora.mgmtdb     ora....db.type 0/2    0/1    ONLINE    ONLINE    node01      ----資源庫
ora....network ora....rk.type 0/5    0/     ONLINE    ONLINE    node01      
ora....SM1.asm application    0/5    0/0    ONLINE    ONLINE    node01      
ora....01.lsnr application    0/5    0/0    ONLINE    ONLINE    node01      
ora.node01.ons application    0/3    0/0    ONLINE    ONLINE    node01      
ora.node01.vip ora....t1.type 0/0    0/0    ONLINE    ONLINE    node01      
ora....SM2.asm application    0/5    0/0    ONLINE    ONLINE    node02      
ora....02.lsnr application    0/5    0/0    ONLINE    ONLINE    node02      
ora.node02.ons application    0/3    0/0    ONLINE    ONLINE    node02      
ora.node02.vip ora....t1.type 0/0    0/0    ONLINE    ONLINE    node02      
ora.oc4j       ora.oc4j.type  0/1    0/2    ONLINE    ONLINE    node01      ----正常online
ora.ons        ora.ons.type   0/3    0/     ONLINE    ONLINE    node01      
ora.scan1.vip  ora....ip.type 0/0    0/0    ONLINE    ONLINE    node01


來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/28612416/viewspace-1351661/,如需轉載,請註明出處,否則將追究法律責任。

相關文章