Sqlplus: what is the solution of error while loading shared libraries
Today, I would like to talk to you about what the solution of sqlplus: error while loading shared libraries is. Many people may not know much about it. In order to make you understand better, the editor has summarized the following content for you. I hope you can get something from this article.
Yesterday, during the training for the trainees, after installing the database, the following error occurred in performing sqlplus.
After building the oracle library, execute the sqlplus command:
[oracle@localhost database] $sqlplus / nolog
Sqlplus: error while loading shared libraries: / oracle/app/product/11.2.0/lib/libclntsh.so.11.1: cannot restore segment prot after reloc: Permission denied
Cause of the problem: SELinux was turned on when Linux was installed
Solution: shut down SELinux
The first method
(1) check the status of SELinux. An Enforcing indicates that SELinux is enabled.
[root@mydb] # getenforce
Enforcing
(2) execute setenforce 0 to set SELinux to permissive mode (that is, temporarily close SElinux)
[root@mydb] # setenforce 0
(3) verify the result of the previous step
[root@mydb] # getenforce
Permissive
The disadvantage of this method is that when the system is rebooted, the SELinux returns to the Enforcing state, and the execution of sqlplus will still report an error.
The second method
Change the SELinux=enforcing in / etc/selinux/config to SELinux=disabled with your root account, and then change it as follows:
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
# enforcing-SELinux security policy is enforced.
# permissive-SELinux prints warnings instead of enforcing.
# disabled-SELinux is fully disabled.
SELINUX=disabled
# SELINUXTYPE= type of policy in use. Possible values are:
# targeted-Only targeted network daemons are protected.
# strict-Full SELinux protection.
SELINUXTYPE=targeted
Restart the system for the settings to take effect:
# reboot
After reading the above, do you have any further understanding of the solution of sqlplus: error while loading shared libraries? If you want to know more knowledge or related content, please follow the industry information channel, thank you for your support.