升级了下 php

看到 wayne 新把上的 VPS 里面 php5-cgi 类似的配置占用内存却比我小得多,发现是他的 php5 版本高一点。我这里 console 访问不了,不敢冒险升级整个系统,于是下最新的 php-5.2.6,装上了依赖包,开始编译…

8 分钟后,编译完成,汗…,VPS 的 CPU 频率是 116Mhz,又运行了好几分钟的 make test,才想到我干嘛要测试?于是中断,make install,重启 lighttpd,一切正常,内存占用稍小了一点,每个 php5-cgi进程比原来少了 1M,效果还行。

为了保险,运行 php5-cgi -m 列出当前支持的模块,然后根据这个列表写 configure 参数。我用的 lighttpd + fastcgi,最后用到的参数如下,注意我是要彻底覆盖现有的 PHP。

./configure \
--prefix=/usr \
--sysconfdir=/etc \
--enable-fastcgi \
--with-bcmath \
--with-bz2 \
--with-calendar \
--with-ctype \
--with-date \
--with-dba \
--with-dom \
--with-exif \
--with-filepro \
--with-ftp \
--with-gettext \
--with-hash \
--with-iconv \
--with-libxml \
--with-mbstring \
--with-mime_magic \
--with-mysql \
--with-openssl \
--with-pcre \
--with-posix \
--with-Reflection \
--with-session \
--with-shmop \
--with-SimpleXML \
--with-soap \
--with-sockets \
--with-SPL \
--with-standard \
--with-sysvmsg \
--with-sysvsem \
--with-sysvshm \
--with-tokenizer \
--with-wddx \
--with-xml \
--with-xmlreader \
--with-xmlwriter \
--with-zlib

0 Comments so far

  1. There are currently no comments.
Leave a Comment?


« 豆沙绿  —  支付宝+招行:支付有多难 »

Tags

Blogroll

Fairy World | STUPiD | 阅微草堂 | ShelleX | 流浪五天