[oracle@node1 bin]$ srvctl /u01/oracle/10.2.0/db_1/jdk/jre/bin/java: error while loading shared libraries: libpthread.so.0: cannot open shared object file: No such file or directory
提示说是bin路径不正确
[oracle@node1 bin]$ which srvctl
/u01/oracle/10.2.0/db_1/bin/srvctl
[oracle@node1 bin]$ echo $CRS_HOME
/u01/oracle/product/10.2.0/crs_1
发现srvctl的路径果然不正确,跟我自己设置的CRS_HOME不一致,就考虑到是环境变量的问题:
[oracle@node1 bin]$ 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 ORACLE_SID=mydb1
export ORACLE_BASE=/u01/oracle export CRS_HOME=$ORACLE_BASE/product/10.2.0/crs_1 export ORACLE_HOME=$ORACLE_BASE/10.2.0/db_1
export LD_LIBRARY_PATH=$ORACLE_HOME/lib
export PATH=$ORACLE_HOME/bin:$CRS_HOME/bin:/bin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/X11R6/bin
export EDITOR=vi
export PATH
[oracle@node2 ~]$ cd $CRS_HOME/bin
[oracle@node2 bin]$ vi srvctl
修改以下两行:
#Remove this workaround when the bug 3937317 is fixed
LD_ASSUME_KERNEL=2.4.19
export LD_ASSUME_KERNEL
添加 unset LD_ASSUME_KERNEL
[oracle@node1 bin]$ cd /u01/oracle/10.2.0/db_1/bin/
[oracle@node1 bin]$ vi srvctl
老方法
#Remove this workaround when the bug 3937317 is fixed
LD_ASSUME_KERNEL=2.4.19
export LD_ASSUME_KERNEL
添加 unset LD_ASSUME_KERNEL