
How to install HTTP Apache, MySql, PHP, PhpMyAdmin from source
Install HTTP Apache from source
1. Download source httpd-2.2.29.tar.gz from http://httpd.apache.org/download.cgi
2. Copy the downloaded file to folder where you want to install apache http server
3. Extract the file at this location, command to extract
tar -zxvf httpd-2.4.12.tar.gz
cd httpd-2.4.12
4. Download apr-1.5.2.tar.gz and apr-util-1.5.4.tar.gz and extract the files at httpd-2.4.12/srclib/ director
a). Download apr-1.5.2.tar.gz and apr-util-1.5.4.tar.gz from https://apr.apache.org/download.cgi
b). Extract these files and execute these command
tar -zxvf apr-1.5.2.tar.gz
mv apr-1.5.2 apr
mv apr httpd-2.4.12/srclib/
tar -zxvf apr-util-1.5.4.tar.gz
mv apr-util-1.5.4 apr-util
mv apr-util httpd-2.4.12/srclib/
5. The next step is to configure the Apache source tree for your particular platform and personal requirements. This is done using the script configure included in the root directory of the distribution.
Run the below command at the root of the distribution, specifying the path of installation as prefix
./configure --prefix=/opt/software/apache --with-included-apr
6. If PCRE – Perl Compatible Regular Expressions library error occurs, then we have to download the source code from http://www.pcre.org, or install a Port or Package. If your build system can’t find the pcre-config script installed by the PCRE build, point to it using the –with-pcre parameter. On some platforms, you may have to install the corresponding -dev package to allow httpd to build against your installed copy of PCRE.
7. After the successfully configure run the below command one-by-one
make
make install
8. Check the server settings
cd /opt/software/apache/conf/
vi httpd.conf
a/. ServerRoot
b/. Listen 80
c/. ServerName test.com:80
d/. DocumentRoot
9. Run the server
cd /opt/software/apache/bin/
./apachectl start
Click here for
- How to install MySql from source
- How to install PHP from source
- How to install PhpMyAdmin from source
Jkoder.com Tutorials, Tips and interview questions for Java, J2EE, Android, Spring, Hibernate, Javascript and other languages for software developers