• Linux安装PHP加速器Xcache


    XCache 是一个又快又稳定的 PHP opcoolcode 缓存器. 经过良好的测试并在大流量/高负载的生产机器上稳定运行. 经过(在linux 上)测试并支持所有现行 PHP 分支的最新发布版本, 如 PHP_4_3 PHP_4_4 PHP_5_0 PHP_5_1 PHP_5_2 HEAD(6.x), 并支持线程安全/Windows. 与同类 opcoolcode 缓存器相比更胜一筹, 比如能够快速跟进 PHP 版本.下面介绍如何安装配置。
    1、安装xcache

    wget http://xcache.lighttpd.net/pub/Releases/1.3.2/xcache-1.3.2.tar.gz
    tar -zxvf xcache-1.3.2.tar.gz
    cd xcache-1.3.2
    phpize
    ./configure --enable-xcache
    make
    make install www.2cto.com
    2、配置xcache
    打开php.ini文件,增加如下代码:

    [xcache-common]
    ; change me - 64 bit php => /usr/lib64/php/modules/xcache.so
    ; 32 bit php => /usr/lib/php/modules/xcache.so
    zend_extension = /usr/lib64/php/modules/xcache.so
     
    [xcache.admin]
    xcache.admin.auth = On
    xcache.admin.user = "mOo"
    ; xcache.admin.pass = md5($your_password)
    xcache.admin.pass = ""
     
    [xcache]
    xcache.shm_scheme =        "mmap"
    xcache.size  =               32M
    xcache.count =                 1
    xcache.slots =                8K
    xcache.ttl   =              3600
    xcache.gc_interval =         300
     
    ; Same as aboves but for variable cache
    ; If you don't know for sure that you need this, you probably don't
    xcache.var_size  =            0M
    xcache.var_count =             1
    xcache.var_slots =            8K
    xcache.var_ttl   =             0
    xcache.var_maxttl   =          0
    xcache.var_gc_interval =     300
     
    ; N/A for /dev/zero
    xcache.readonly_protection = Off
     
    xcache.mmap_path =    "/dev/zero"
     
    xcache.cacher =               On
    xcache.stat   =               On
    注意修改zend_extension = /usr/lib64/php/modules/xcache.so为正确的路径。

  • 相关阅读:
    java 复习001
    Some_sort_algorithms
    Install_pygments
    Install_ruby
    Ubuntu_wifi&pppoe
    Some_problem_with_octopress
    复习C语言
    VSim [a Racing-simulator by Vell001]
    Hello, Github Blog
    我的新计划 《2Dof Racing Simulator》2014/3/9 20:30:00
  • 原文地址:https://www.cnblogs.com/moqiang02/p/4061154.html
Copyright © 2020-2023  润新知