xcache:php Cache Extension Installation configuration

Source: Internet
Author: User
One, RPM installation configuration XCache

1.xcache for cache acceleration

PHP third-party extension, stored on the Epel source, the installation package is Php-xcache, on the CentOS6 generally three times times the promotion

[root@localhost~]# Yum List all | grep XCache

Xcache-admin.noarch graphical management interface, no installation required

2.RPM Mounting Php-xcache

[root@localhost~]# Yum insatll-y Php-xcache

3. Configuration files

[root@localhost~]# Cat/etc/php.d/xcache.ini

Generally only xcache.size and Xcache.ttl are adjusted

[Xcache-common]


Extension = xcache.so

Indicates load cache extension, relative path represents/usr/lib64/moduled/

[Xcache.admin]


Xcache.admin.enable_auth = On

Start Management interface

Xcache.admin.user = ""

Administrator user Name

Xcache.admin.pass = ""

Administrator-Encrypted (MD5) password

[XCache]


Xcache.shm_scheme = "Mmap"

Memory management methods: memory mapping

Xcache.size = 60M

The size of the cache in memory

Xcache.count = 1

Number of Cache component segments

Xcache.slots = 8K

Cache slots, altogether 64M, each 8k

Xcache.ttl = 0

Cache expires, 0 means permanent

Xcache.gc_interval = 0


4. Restart PHP service: See how PHP is deployed

Modules mode: [root@localhost ~]# systemctl Restart httpd

fcgi mode: [root@localhost ~]# systemctl Restart PHP-FPM

Second, compile and install the configuration XCache

1. Dependent Package Installation

#yum Install Php-devel

2. Compiling the installation

#cd xcache-3.2.0

# phpize

#./configure--enable-xcache--with-php-config=/usr/bin/php-config

#make && make Install

Attention:

1) phpize command for current directory generation configure script

2) XCache is installed as a module, generating module installation position/usr/lib64/php/modules/xcache.so

3)--with-php-config can not be specified, will automatically resolve the dependency path

3. Configuration files

#cp xcache.ini/etc/php.d/

  • Related Article

    Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.