Oracle 11g RAC在grid使用者下登陸sqlplus報錯"Error 6 SP2-0667 SP2-0750"

feelpurple發表於2016-09-06
Oracle 11g RAC在grid使用者下登陸sqlplus報錯
[root@srv05 ~]# su - grid

[grid@srv05 ~]$ sqlplus / as sysasm
Error 6 initializing SQL*Plus
SP2-0667: Message file sp1.msb not found
SP2-0750: You may need to set ORACLE_HOME to your Oracle software directory
[grid@srv05 ~]$ echo $ORACLE_HOME
/u01/app/12.1.0/grid
[grid@srv05 ~]$ cd $ORACLE_HOME
[grid@srv05 grid]$ ll
total 0
[grid@srv05 grid]$ cd ..
[grid@srv05 12.1.0]$ ll
total 8
drwxrwxr-x  2 grid oinstall 4096 Aug 31 16:38 grid
drwxr-xr-x 73 root oinstall 4096 Sep  1 15:54 grid_1
[grid@srv05 12.1.0]$ cd grid_1/
[grid@srv05 grid_1]$ ls
addnode     bin          clone  css   dbs        demo         eons  gnsd  hs             inventory  jdk   ldap  md       nls    ologgerd  oracore      osysmond  perl     QOpatch  relnotes  rootupgrade.sh  sqlpatch  suptools  usm  wwg
assistants  cdata        crf    ctss  dc_ocm     diagnostics  evm   gpnp  install        javavm     jlib  lib   mdns     oc4j   OPatch    oraInst.loc  oui       plsql    racg     rest      scheduler       sqlplus   tfa       utl  xag
auth        cfgtoollogs  crs    cv    deinstall  dmu          gipc  has   instantclient  jdbc       JRE   log   network  ohasd  opmn      ord          owm       precomp  rdbms    root.sh   slax            srvm      ucp       wlm  xdk
[grid@srv05 grid_1]$ pwd
/u01/app/12.1.0/grid_1

發現grid使用者的ORACLE_HOME路徑配置有誤,更正為正確的路徑

[grid@srv05 grid_1]$ cd
[grid@srv05 ~]$ cat .bash_profile
# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
    . ~/.bashrc
fi

# User specific environment and startup programs

PATH=$PATH:$HOME/bin

export PATH
export TMP=/tmp
export TMPDIR=/tmp
export ORACLE_HOSTNAME=srv05.gemalto.com
export ORACLE_BASE=/u01/app/grid
export ORACLE_HOME=/u01/app/12.1.0/grid
export ORACLE_SID=+ASM2
export PATH=$ORACLE_HOME/bin:/u01/app/12.1.0/grid_1/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
export DISPLAY=:0.0
umask=022

[grid@srv05 ~]$ vim .bash_profile
# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
    . ~/.bashrc
fi

# User specific environment and startup programs

PATH=$PATH:$HOME/bin

export PATH
export TMP=/tmp
export TMPDIR=/tmp
export ORACLE_HOSTNAME=srv05.gemalto.com
export ORACLE_BASE=/u01/app/grid
export ORACLE_HOME=/u01/app/12.1.0/grid_01
export ORACLE_SID=+ASM2
export PATH=$ORACLE_HOME/bin:/u01/app/12.1.0/grid_1/bin:$PATH
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
export DISPLAY=:0.0
umask=022

[grid@gugong ~]$ sqlplus / as sysasm

SQL*Plus: Release 12.1.0.2.0 Production on Tue Sep 6 10:42:52 2016

Copyright (c) 1982, 2014, Oracle.  All rights reserved.


Connected to:
Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production
With the Real Application Clusters and Automatic Storage Management options

SQL> show parameter dump

NAME                     TYPE     VALUE
------------------------------------ ----------- ------------------------------
background_core_dump             string     partial
background_dump_dest             string     /u01/app/12.1.0/grid_1/rdbms/log
core_dump_dest                 string     /u01/app/grid/diag/asm/+asm/+ASM1/cdump
max_dump_file_size             string     unlimited
shadow_core_dump             string     partial
user_dump_dest                 string     /u01/app/12.1.0/grid_1/rdbms/log

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

相關文章