Three installation methods for PHPmemcache extension-PHP Tutorial-php Tutorial

Source: Internet
Author: User
Three installation methods for PHPmemcache extension. For more information, see code. google. compmemcachedwikiPHPClientComparison. We recommend that you use the new memcached. the installation method is basically the same as below. you only need to install libmemcached first. For more information, see http://code.google.com/p/memcached/wiki/phpclientcomparison. We recommend that you use the new memcached. the installation method is basically the same as below. you only need to install libmemcached first. if you need to enable compression, you also need to install zlib.
Use PECL to compile the shared PECL Extension Library
$ Pecl install extname
Then there is a long string of automatic execution, and the program tells You that You should add "extension = memcache. so "to php. ini, of course, we need to take the generated memcache. so put it in your php Extension Library Directory.
In manual on the official website, pear is used to install the extension. However, an error occurs during actual operations, indicating that memcache cannot be found. let me use pecl install...
Use phpize to compile the shared PECL Extension Library
The above method is to download. You can also perform the installation by yourself, and then install it with phpize.
First, decompress the package, enter the directory, and execute:
$ Phpize
$./Configure
$ Make
# Make install
Put memcache. so in your php extension Library Directory, and then add extension = memcache. so to php. ini.
The last extreme method extends Static Compilation. why is it so difficult? It is said that this process is more efficient than. so. I have never compared it...
You can go to the next package first, decompress it, and put it in the ext directory under the phpsrc directory to be installed. Then:
$ Rm configure
$./Buildconf -- force
$./Configure -- help
$./Configure -- with-memcache
$ Make
$ Make install
A bit messy. there are good articles:
Memcached:
Http://willko.javaeye.com/blog/332993
Http://cn2.php.net/manual/en/book.memcached.php
Http://cn.php.net/manual/en/book.memcache.php
Pecl:
Http://cn2.php.net/manual/en/install.pecl.php
Memcache can be used to study many things, such as a partial hash policy, as a session policy and persistent memcache. Have the opportunity to make fun of others.
-- EOF --

Bytes. We recommend that you use the new memcached. the installation method is basically the same as below. you only need to install libmemcached first...

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.