執行java報錯
Error: failed /usr/admin/software/jdk1.7.0/jre/lib/i386/client/libjvm.so, because /usr/admin/software/jdk1.7.0/jre/lib/i386/client/libjvm.so: cannot restore segment prot after reloc: Permission denied
緣由是SELINUX被開啓了
SELinux(Security-Enhanced Linux) 是美國國家安全局(NSA)對於強制訪問控制的實現,是 Linux® 上最傑出的新安全子系統。NSA是在Linux社區的幫助下開發了一種訪問控制體系,在這種訪問控制體系的限制下,進程只能訪問那些在他的任務中所須要文件。
[root@localhost bin]# vi /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 - SELinux is fully disabled.
SELINUX=enforcing
# SELINUXTYPE= type of policy
in use. Possible values are:
# targeted - Only targeted network daemons are
protected. # strict - Full SELinux protection. SELINUXTYPE=targeted
將SELINUX=enforcing註釋掉便可 臨時關閉用命令:/usr/sbin/setenforce 0