内核: Linux ubuntu 2.6.38-8-generic #42-Ubuntu SMP Mon Apr 11 03:31:50 UTC 2011 i686 i686 i386 GNU/Linux
系统版本: Ubuntu 11.04 32位
打开 http://127.0.0.1 显示成功,但打开 http://127.0.0.1/p.php 出现502错误
/root/lnmp restart
错误信息:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43
| root@ubuntu:~/lnmp0.7-full/php-5.2.17# /root/lnmp restart
=========================================================================
Manager for LNMP V0.7 , Written by Licess
=========================================================================
LNMP is a tool to auto-compile & install Nginx+MySQL+PHP on Linux
This script is a tool to Manage status of lnmp
For more information please visit http:
Usage: /root/lnmp
=========================================================================
Stoping LNMP...
Nginx program is stop
PHP-FPM program is not runing!
Shutting down MySQL
. *
MySQL program is stop
Starting LNMP...
Nginx start successfully!
/root/lnmp: 行 46: /usr/local/php/sbin/php-fpm: 没有那个文件或目录
PHP-FPM start successfully!
Starting MySQL
. *
MySQL start successfully!
|
解决办法:
(打开 /root/lnmp0.7-full/ubuntu.sh
找到 echo "========================= php + php extensions install ==================="
按里面的代码执行的。从 tar zxvf php-5.2.17.tar.gz
开始执行的,下面有具体的)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
| apt-get install libjpeg62 libjpeg62-dev libjpeg-dev
ln -s /usr/lib/i386-linux-gnu/libpng* /usr/lib/
ln -s /usr/lib/i386-linux-gnu/libjpeg* /usr/lib/
cd /root/lnmp0.7-full/ 或者 cd cd /root/lnmp0.7/
tar zxvf php-5.2.17.tar.gz
gzip -cd php-5.2.17-fpm-0.5.14.diff.gz | patch -d php-5.2.17 -p1
cd php-5.2.17/
./buildconf --force
./configure --prefix=/usr/local/php --with-config-file-path=/usr/local/php/etc --with-mysql=/usr/local/mysql --with-mysqli=/usr/local/mysql/bin/mysql_config --with-iconv-dir --with-freetype-dir --with-jpeg-dir --with-png-dir --with-zlib --with-libxml-dir=/usr --enable-xml --enable-discard-path --enable-magic-quotes --enable-safe-mode --enable-bcmath --enable-shmop --enable-sysvsem --enable-inline-optimization --with-curl --with-curlwrappers --enable-mbregex --enable-fastcgi --enable-fpm --enable-force-cgi-redirect --enable-mbstring --with-mcrypt --enable-ftp --with-gd --enable-gd-native-ttf --with-openssl --with-mhash --enable-pcntl --enable-sockets --with-xmlrpc --enable-zip --enable-soap --without-pear --with-gettext --with-mime-magic
make ZEND_EXTRA_LIBS=&
make install
|
这个问题我在vpse论坛上问过了,上面有关于我如何解决的:
http://bbs.vpser.net/thread-3055-1-1.html
附:
LNMP安装教程
LNMPA安装教程