Configuration Record of apache + php in linux
Last Update:2014-05-21
Source: Internet
Author: User
License libmcrypt-2 .. linux apache + php build configuration records chapter 1st environment description 1.1 system description Centos 6.2 (minimal installation) 1.2 license chapter 2nd Apache build instructions 2.1 install dependency package yum install make openl Dap-devel ntp vim-enhanced gcc-c ++ gcc-g77 flex bison autoconf bzip2-devel ncurses-devel openssl-devel libtool * zlib-devel libxml2-devel libjpeg-devel libpng-devlibel TIFF-devel fontconfig -devel freetype-devel libXpm-devel gettext-devel curl pam-devel openldap-devel e2fsprogs-devel krb5-devel apr-1.4.2.tar.gz libidn-devel-y2.2 install aprtar-zxvf apr-1.4.2.tar.gz cd. /configure- -Prefix =/usr/local/aprmake & make install2.3 install apr-utiltar-zxvf apr-util-1.3.10.tar.gzcd. /configure \ -- prefix =/usr/local/apr-util \ -- with-apr =/usr/local/apr make & make install2.4 install pcretar-zxvf pcre-8.10.tar.gzcd. /configure -- prefix =/usr/local/pcremake & make install2.5 install apache. /configure \ -- prefix =/usr/local/apache \ -- with-apr-util =/usr/local/apr-util /\-- With-pcre =/usr/local/pcre/\ -- with-apr =/usr/local/apr/make & make install2.6 configuration file description/usr/local/apache/conf /httpd. confDocumentRoot "/usr/local/apache/htdocs" to modify this item to configure the project running directory. Start file/usr/local/apache/bin/apachectl chapter 3rd Php build instructions 3.1 install libmcrypttar xvf libmcrypt-2.5.8.tar.gz. /configuremake & make install3.2 install mhashtar xvf mhash-0.9.9.9.tar.gzcd mhash-0.9.9.9. /configure make & make install3.3 install php. /configure -- prefix =/usr/local/php \ -- with-apxs2 =/usr/local/apache/bin/apxs \ -- with-config-file-path =/usr/local/ php/etc make & make install cp php. ini-production/usr/local/php/etc/php. ini3.4 error message modify description configure: error: Cannot find ldap libraries in/usr/libln-s/usr/lib64/libldap */usr/lib/configure: error: libjpeg. (a | so) not found. ln-s/usr/lib64/libjpeg. so/usr/lib/libjpeg. soconfigure: error: libpng. (a | so) not found. ln-s/usr/lib64/libpng. so/usr/lib/Chapter 4th modify configuration and test 4.1 modify apache configuration file support php modify DirectoryIndex index.html to DirectoryIndex index.html index. php and add AddType application/x-httpd-php. php4.2 test php support creating test php page test. php, stored in the home directory of the website, After the apache service is restarted, visit http: // ip/test. php to view the site, which indicates that php has been built;