Issue : We are getting following error messages while using Oracle’s SQL*Plus client on Linux.
To avoid these messages, we need to set correct environment variables :
Error messages:
servername01 sql $ sqlplus jdb1/password@sconnect_string
sqlplus: error while loading shared libraries: libsqlplus.so: cannot open shared object file: No such file or directory
Verify:
servername01 ~ $ locate libsqlplus.so/u01/app/oracle/product/11.1.0/client/lib/libsqlplus.so
Solution:
1) Add following env variable into oracle .profile or .bash_profile
# .bash_profile
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
# User specific environment and startup programs
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=/u01/app/oracle/product/11.1.0/client
export LD_LIBRARY_PATH=/u01/app/oracle/product/11.1.0/client/lib
export PATH=$ORACLE_HOME/bin:$ORACLE_HOME/lib:$PATH:$HOME/.local/bin:$HOME/bin
OR
2) Linux server: For all User - Add following environment variable into /etc/profile:
export LD_LIBRARY_PATH=/u01/app/oracle/product/11.1.0/client/lib
export ORACLE_BASE=/u01/app/oracle
export PATH=/u01/app/oracle/product/11.1.0/client/bin:/u01/app/oracle/product/11.1.0/client/lib:/u01/app/oracle/product/11.1.0/client/jdk/bin:/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/usr/java/jdk1.5.0_05/bin:/opt/dell/srvadmin/bin:/home/oracle/bin:$PATH:$HOME/bin
export ORACLE_HOME=/u01/app/oracle/product/11.1.0/client
To avoid these messages, we need to set correct environment variables :
Error messages:
servername01 sql $ sqlplus jdb1/password@sconnect_string
sqlplus: error while loading shared libraries: libsqlplus.so: cannot open shared object file: No such file or directory
Verify:
servername01 ~ $ locate libsqlplus.so/u01/app/oracle/product/11.1.0/client/lib/libsqlplus.so
Solution:
1) Add following env variable into oracle .profile or .bash_profile
# .bash_profile
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
# User specific environment and startup programs
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=/u01/app/oracle/product/11.1.0/client
export LD_LIBRARY_PATH=/u01/app/oracle/product/11.1.0/client/lib
export PATH=$ORACLE_HOME/bin:$ORACLE_HOME/lib:$PATH:$HOME/.local/bin:$HOME/bin
OR
2) Linux server: For all User - Add following environment variable into /etc/profile:
export LD_LIBRARY_PATH=/u01/app/oracle/product/11.1.0/client/lib
export ORACLE_BASE=/u01/app/oracle
export PATH=/u01/app/oracle/product/11.1.0/client/bin:/u01/app/oracle/product/11.1.0/client/lib:/u01/app/oracle/product/11.1.0/client/jdk/bin:/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/usr/java/jdk1.5.0_05/bin:/opt/dell/srvadmin/bin:/home/oracle/bin:$PATH:$HOME/bin
export ORACLE_HOME=/u01/app/oracle/product/11.1.0/client
No comments:
Post a Comment