CentOS5.6中装好Oracle11g之后,启动sqlplus报错

--整理以前的学习笔记

CentOS5.6中装好Oracle11g之后,启动sqlplus报错

sqlplus: error while loading shared libraries: /u01/app/oracle/product/11.2.0/dbhome_1/lib/libclntsh.so.11.1: cannot restore segment prot after reloc: Permission denied

网上查资料需要禁用selinux
root用户登录
使用cd命令切换当前目录到 /etc/selinux
使用vim打开config文件
找到里面的SELINUX条目,设置成disabled
重启系统


/etc/selinux/config大致内容如下:

# 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 - No SELinux policy is loaded.
SELINUX=enforcing
# SELINUXTYPE= can take one of these two values:
# targeted - Only targeted network daemons are protected.
# strict - Full SELinux protection.
SELINUXTYPE=targeted

但是我禁用的时候设置错了,本来应该要把SELINUX=enforcing改为disabled,但是我却把SELINUXTYPE=targeted改成了disabled

导致重启之后报错unable to load selinux policy. kernel panic-not syncing: attempated to kill init!系统进不去


解决方法:
通过编辑Grub启动项解决。
在Grub启动菜单上按e进入编辑模式,在启动项最后面加上 enforcing=0 ,回车,然后按b启动即可
kernel /vmlinuz-2.6.19-prep ro root=LABEL=/ rhgb quiet 后面加上一个 enforcing=0,然后启动即可
启动后再把/etc/selinux/config正确地修改回来
如下所示
# 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 - No SELinux policy is loaded.
SELINUX=disabled
# SELINUXTYPE= can take one of these two values:
# targeted - Only targeted network daemons are protected.
# strict - Full SELinux protection.
SELINUXTYPE=targeted


参考资料:
http://www.crypt.gen.nz/selinux/disable_selinux.html
http://minyupeng.blog.163.com/blog/static/221544992011462156662/

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/26524307/viewspace-1061198/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/26524307/viewspace-1061198/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值