Home > Article > Backend Development > lnmp how to reinstall php
Lnmp method to reinstall php: First enter the ext directory of the php installation directory; then execute the command "cd /root/lnmp0.4-full/php-5.2.10/ext/"; then execute the command " make && make install" and modify php.ini.
Recommendation: "PHP Video Tutorial"
1. Installation library:
CentOS :yum install libc-client-devel Debian:apt-get install libc-client-dev
2 , enter the ext directory of the php installation directory
For example, if the php installation directory is: /root/lnmp0.4-full/php-5.2.10/
, then execute: cd /root/lnmp0 .4-full/php-5.2.10/ext/
We need to install the imap module, execute cd imap/
and then execute /usr/local/php/bin/phpize. Return information:
Configuring for: PHP Api Version: 20041225 Zend Module Api No: 20060613 Zend Extension Api No: 220060519
Execute the following command:
[root@vpser imap]# ./configure --with-php-config=/usr/local/php/bin/php-config [root@vpser imap]# make && make install
Return:
Build complete. Don't forget to run 'make test'. Installing shared extensions: /usr/local/php/lib/php/extensions/no-debug-non-zts-20060613/
has been successful, then modify /usr/local/php/etc/php.ini
Search: extension = then add extension = "imap.so" after the last extension=
Save and execute /root/lnmp restart to restart.
The above is the detailed content of lnmp how to reinstall php. For more information, please follow other related articles on the PHP Chinese website!