PHP compiled Redis extensions

Source: Internet
Author: User

1. Download the installation package

Come to PHP's official extension and search for Redis, find the stable version of the stable package, download it locally, and prepare for the extended installation

Pecl (The PHP Extension Community Library) Address: http://www.pecl.php.net/

Redis:http://www.pecl.php.net/get/redis-2.2.4.tgz

2, compiling the expansion pack

First unzip the Redis expansion pack, then go to the directory and execute:

/usr/local/php/bin/phpize

If you do not have an error, proceed:

./configure--with-php-config=/usr/local/php/bin/php-config

If configure error is not reported , continue execution:

Make && make install

After success, you will be prompted with the redis.so file directory, as follows:

Then copy the redis.so file to the PHP extension directory, and then modify the php.ini file to add a line:

Extension=redis.so

Restart the server, you can see the extension information in the phpinfo ()!



PHP compiled Redis extensions

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.