# /www/wdlinux/php/bin/php -m |grep memcache
PHP Warning: PHP Startup: Unable to load dynamic library '/www/wdlinux/php/lib/php/extensions/no-debug-non-zts-20090626/php_curl.dll' - /www/wdlinux/php/lib/php/extensions/no-debug-non-zts-20090626/php_curl.dll: cannot open shared object file: No such file or directory in Unknown on line 0
PHP Warning: PHP Startup: memcache: Unable to initialize module
Module compiled with module API=20060613
PHP compiled with module API=20090626
These options need to match
in Unknown on line 0
cd /tmp
wget -c https://github.com/downloads/libevent/libevent/libevent-2.0.21-stable.tar.gz
wget -c http://memcached.googlecode.com/files/memcached-1.4.15.tar.gz
wget -c http://pecl.php.net/get/memcache-2.2.7.tgz
tar xf libevent-2.0.21-stable.tar.gz
cd libevent-2.0.21-stable
./configure --prefix=/usr
make
[ $? != 0 ] && exit
make install
cd ..
tar xf memcached-1.4.15.tar.gz
cd memcached-1.4.15
./configure --prefix=/www/wdlinux/memcached --with-libevent=/usr
make
[ $? != 0 ] && exit
make install
cd ..
if grep -qi 'debian\|ubuntu' /etc/issue; then
wget http://www.wdlinux.cn/conf/init.d/init.memcached-ubuntu -O /www/wdlinux/init.d/memcached
chmod 755 /www/wdlinux/init.d/memcached
ln -s /www/wdlinux/init.d/memcached /etc/init.d/memcached
update-rc.d -f memcached defaults
update-rc.d -f memcached enable 235
else
wget http://www.wdlinux.cn/conf/init.d/init.memcached -O /www/wdlinux/init.d/memcached
chmod 755 /www/wdlinux/init.d/memcached
ln -s /www/wdlinux/init.d/memcached /etc/init.d/memcached
chkconfig --level 35 memcached on
fi
touch /www/wdlinux/etc/memcached.conf
service memcached start
###
tar zxvf memcache-2.2.7.tgz
cd memcache-2.2.7
/www/wdlinux/php/bin/phpize
./configure --enable-memcache --with-php-config=/www/wdlinux/php/bin/php-config --with-zlib-dir
make
[ $? != 0 ] && exit
make install
grep -q 'memcache.so' /www/wdlinux/etc/php.ini
if [ $? != 0 ]; then
echo "
[memcache]
extension_dir ="/www/wdlinux/php/lib/php/extensions/$ext_dir"
extension=memcache.so" >> /www/wdlinux/etc/php.ini
fi
if [ -d /www/wdlinux/apache ]; then
service httpd restart
else
service nginxd restart
fi
echo
echo "memcache install is OK"
echo
TAT 求助。。。。。。。。完全不知道该怎么办了..........我是不是要写死5.3.17这个安装目录?