Compile and install php5.3.8 (including PHP-FPM)

Source: Internet
Author: User
Tags snmp

# WgetHttp://cn2.php.net/get/php-5.3.8.tar.gz/from/cn.php.net/mirror
# Tar-zxvf php-5.3.8.tar.gz
# Cd php-5.3.8
#. /Configure -- prefix =/usr/local/PHP -- enable-FPM -- With-libevent-Dir =/usr -- With-mcrypt =/usr/local/libmcrypt -- With-zlib -- enable-mbstring -- With-OpenSSL -- With-mysql -- With-mysqli -- With-mysql-sock -- With-Gd -- With-JPEG-Dir =/usr/lib -- enable-Gd -Native-TTF -- without-SQLite -- enable-PDO -- With-PDO-mysql -- With-gettext -- With-curl -- With-PDO-mysql -- enable-sockets -- enable-bcmath -- enable-XML -- with-bz2 -- With-gettext -- With-SNMP -- enable-zip -- With-SNMP

I reported an error during 64-bit centos Compilation:Configure: Error: MySQL Configure Failed.Please check config. Log

After searching, we can find the following solutions:

Find/usr/lib64/Libltdl. so.3.1.4. Run the following command in this directory:

Ln-SV libltdl. So.3.1.4Libltdl. So

The following content will eventually appear,
+ -------------------------------------------------------------------- +
| License: |
| This software is subject to the PHP license, available in this |
| Distribution in the file license. By continuing this installation |
| Process, you are bound by the terms of this License Agreement. |
| If you do not agree with the terms of this License, you must abort |
| The installation process at this point. |
+ -------------------------------------------------------------------- +
Thank you for using PHP.

Install
# Make
# Make install
MobilePHP. ini
# Cp/usr/local/php-5.3.8/PHP. ini-development/usr/local/PHP/lib/PHP. ini

About PHP-FPM
Php5.3.8 includes PHP-FPM by default,

Php-FPM configuration file php-fpm.conf in/usr/local/PHP/etc <============ of course you have to watch PHP installed there
Php-fpm.conf file name here is php-fpm.conf.default
# Cp php-fpm.conf.default php-fpm.conf <========== copy a copy and rename

Php-FPM under/usr/local/PHP/sbin/
#/Usr/local/PHP/sbin/PHP-FPM ======== start PHP-FPM
Startup error Resolution:
Alert: [pool WWW] PM. min_spare_servers (0) must be a positive value
Edit the php-fpm.conf to find the PM. min_spare_servers removal; number, note that the non-commented content pm. min_spare_servers
Alert: [pool WWW] PM. max_spare_servers (0) must be a positive value
Edit the php-fpm.conf to find the PM. max_spare_servers removal; number, which is also not annotated with PM. max_spare_servers
Warning: [pool WWW] PM. start_servers is not set. It's been set to 20.
Edit the php-fpm.conf to locate pm. start_servers removal;, which is also not annotated with PM. start_servers
Error: BIND () for address '127. 0.0.1: 9000 'failed: address already in use (98)
# Netstat-ntlpps-Ef | grep PHP: Check the process. There are n multi-process instances.
Nobody 26152 26151 0? 00:00:00 PHP-FPM: pool WWW
Nobody 26153 26151 0? 00:00:00 PHP-FPM: pool WWW
Nobody 26154 26151 0? 00:00:00 PHP-FPM: pool WWW
Nobody 26155 26151 0? 00:00:00 PHP-FPM: pool WWW
...........................
# Killall PHP-FPM end all PHP-FPM Processes
Start PHP-FPM again
#/Usr/local/PHP/sbin/PHP-FPM
Successful

 

Source: http://www.linuxdiyf.com/viewarticle.php? Id = 217611

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.