ZendGuardLoader安裝

遇到的問題php

php -vlinux

Zend Guard Loader requires Zend Engine API version 220090626.nginx

The Zend Engine API version 220121212 which is installed, is newer.
Contact Zend Technologies at http://www.zend.com/ for a later version of Zend Guard Loader.web

PHP 5.5.7 (cli) (built: Jul 1 2015 23:02:10) 
Copyright (c) 1997-2013 The PHP Group
Zend Engine v2.5.0, Copyright (c) 1998-2013 Zend Technologies
with Zend OPcache v7.0.3-dev, Copyright (c) 1999-2013, by Zend Technologiescentos

服務器系統:centos6.5服務器

web服務器:nginxui

 

下載ZendGuardLoader(要根據機型下載,可經過lscpu查看,下載32位仍是64位,個人是64位的),官網下載須要註冊登陸spa

zend-loader-php5.5-linux-x86_64.tar.gz,命令行

說明:PHP5.3以上的版本再也不支持Zend Optimizer,已經被全新的 Zend Guard Loader 取代,下面是安裝Zend Guard具體步驟,如下操做均在終端命令行執行code

 

關閉SELINUX
vi /etc/selinux/config #SELINUX=enforcing #註釋掉 #SELINUXTYPE=targeted #註釋掉 SELINUX=disabled #增長 :wq 保存,關閉 reboot #重啓系統

 

二、安裝Zend Guard

mkdir /usr/zend       #創建Zend Guard安裝目錄
tar xvfz zend-loader-php5.5-linux-x86_64.tar.gz #解壓安裝文件 cp zend-loader-php5.5-linux-x86_64/ZendGuardLoader.so /usr/zend/ #拷貝文件到安裝目錄

 

三、配置Zend Guard

cp  /etc/php.ini    /etc/php.inibak   #修改以前先備份
vi /etc/php.ini #編輯文件 在最後位置添加如下內容 [Zend Guard] zend_extension=/usr/zend/ZendGuardLoader.so zend_loader.enable=1 zend_loader.disable_licensing=0 zend_loader.obfuscation_level_support=3 zend_loader.license_path=

四、重啓nginx服務器

nginx/sbin/nginx -s reload

 

5.結果:

相關文章
相關標籤/搜索