selinux导致安装php错误解决

如果提示”/usr/local/php-5.2.5/sapi/cli/php:error while loading shared libraries: /usr/local/mysql/lib/libmysqlclient.so.16:cannot restore segment prot after reloc: Permission denied”

原因:SELinux

解决方法:chcon –t texrel_shlib_t /usr/local/mysql/lib/libmysqlclient.so.16