先把httpd的服务关了。。
./configure --prefix=/usr/local/apache-2.4 --enable-so --enable-modules=all --enable-rewrite --enable-deflate --enable-socache-memcache --enable-buffer --enable-proxy-fcgi --enable-session --enable-session-cookie --enable-cache-disk --enable-cache --enable-file-cacheso
编译参数看上面。。我以为加的cache比较多。。又加了新模块session。。有fcgi。。rewrite。在测试机上测试。还有个buffer。
然后make make install 不知道是不是我的原因。。在make 的时候 测试机。突然关机了。。。查log,好像是给人关的。。但是没人弄啊。。不知道怎么回事。。
完了以后
# cp /usr/local/httpd/bin/apachectl /etc/init.d/httpd
# vi /etc/init.d/httpd 在第二行加入以下两行内容
1
2
# chkconfig –add httpd
# chkconfig –level 2345 httpd on
# chown -R www:www /usr/local/httpd
加入开机启动。。然后。修改下。用户和组。。给目录权限。。目录用户权限。。service httpd start ok。。下一步就是编译你的php。。。
再贴一次我的参数。。
./configure --prefix=/usr/local/php-5.3.10 --with-config-file-path=/usr/local/php-5.3.10/etc --with-apxs2=/usr/local/apache-2.4/bin/apxs --with-mysql=/usr/local/mysql-5.5.16/ --with-mysqli=/usr/local/mysql-5.5.16/bin/mysql_config --with-iconv-dir=/usr/local/libiconv --with-freeype-dir --with-jpeg-dir --with-png-dir --with-zlib --with-libxml-dir=/usr --enable-xml --with-curl --with-curlwrappers --with-mhash --with-mcrypt --with-gd --enable-gd-native-ttf --with-xsl --with-openssl --with-xmlrpc --without-pear --enable-zip --enable-soap --enable-mbstring --enable-ftp --enable-sockets --enable-pcntl --enable-bcmath --enable-shmop --enable-sysvsem --enable-inline-optimization --disable-rpath --enable-mbregex
出去吃饭了。。回了在写。
回来了
然后
配置
# vi /usr/local/httpd/conf/httpd.conf
找到
1
下行添加
1
找到
1
2
3
修改为
1
2
3