In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/03 Report--
Editor to share with you the example analysis of PHP in LNMP, I believe that most people do not know much about it, so share this article for your reference, I hope you can learn a lot after reading this article, let's go to know it!
Wget http://cn2.php.net/distributions/php-5.4.37.tar.bz2
Tar jxf php-5.4.37.tar.bz2
Useradd-s / sbin/nologin php-fpm
Cd php-5.4.37
. / configure-- prefix=/usr/local/php-- with-config-file-path=/usr/local/php/etc-- enable-fpm-- with-fpm-user=php-fpm-- with-fpm-group=php-fpm-- with-mysql=/usr/local/mysql-- with-mysql-sock=/tmp/mysql.sock-- with-libxml-dir-- with-gd-- with-jpeg-dir-- with-png-dir-- with-freetype-dir-- with-iconv-dir-- with- Zlib-dir-with-mcrypt-enable-soap-enable-gd-native-ttf-enable-ftp-enable-mbstring-enable-exif-disable-ipv6-with-curl
Make & & make install
Cp php.ini-production / usr/local/php/etc/php.ini
Copy the startup script:
Cp / usr/local/src/php-5.4.37/sapi/fpm/init.d.php-fpm / etc/init.d/php-fpm
Mv / usr/local/php/etc/php-fpm.conf.default / usr/local/php/etc/php-fpm.conf
Chmod 755 / etc/init.d/php-fpm
Chkconfig-add php-fpm
Service php-fpm start
Chkconfig php-fpm on
Compilation error:
Error 7
Error content: configure: error: mcrypt.h not found. Pleasereinstall libmcrypt
The centos source cannot install libmcrypt-devel. There is no package with mcrypt due to copyright.
There are two ways to solve this problem, one is to use a third-party source, which can also be installed using yum, which is simple and convenient, but the disadvantage is that the third-party source feels more or less unreliable.
Error content: configure: error: mcrypt.h not found. Please reinstall libmcrypt
There are a lot of searches on the Internet, including the yum install libmcrypt libmcrypt-devel that comes with it, which is ineffective.
Go to SourceForget to download libmcrypt http://sourceforge.NET/projects/mcrypt/files/Libmcrypt/, the latest version is mcrypt 2.6.7.gz. Download the installation and still report an error libmcrypt can not be found!
Continue to test, the final installation is successful, feeling that the version is too high.
Method (version 2.5.7 is used for key points):
[html] view plain copy
# using wget, you can download it from the following path
Wget ftp://mcrypt.hellug.gr/pub/crypto/mcrypt/attic/libmcrypt/libmcrypt-2.5.7.tar.gz
# decompression
Tar-zxvf libmcrypt-2.5.7.tar.gz
# enter the directory
Cd libmcrypt-2.5.7
# compile (installed to / usr/local/lib/ by default)
. / configure-- prefix=/usr/local/libmcrypt
# perform installation
Make & & make install
Solution one
1. Install a third-party yum source
Wget http://www.atomicorp.com/installers/atomic
Sh. / atomic
2. Use yum command to install
Yum install php-mcrypt libmcrypt libmcrypt-devel
The above is all the content of the article "sample Analysis of PHP in LNMP". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.