How to install Apache Http server in Fedora Core
There are two ways to install Apache Http server in Fedora Core, either with yum command to install automatically and manual install it by compiling the source.
Steps to install automatically
1) Search Apache package with yum search command
yum search httpd
P.S Apache http server in fedora is called httpd
2) Get the Apache package name, and issue the yum install command. You need sudo privileged to install it.
sudo yum install httpd
3) Done, open your favour internet browser , and type “http://localhost”
Where the Apache Http server installed?
[root@snake init.d]# find / -name httpd /var/lock/subsys/httpd /var/log/httpd /usr/sbin/httpd /usr/lib/httpd /etc/sysconfig/httpd /etc/rc.d/init.d/httpd /etc/logrotate.d/httpd /etc/httpd
Steps to install manually
1) Download the Apache Http server from Apache website (e.g httpd-2.2.13.tar.gz)
2) Unzip it
tar xvfz httpd-2.2.13.tar.gz
3) Configure the folder location
./configure --prefix=/usr/local/apache --enable-shared=max
The option –prefix is indicate the path where the server will installed, and –enable-shared is activated the load module support, it’s better turn it on during installation stage for the future extend or customise the functionality without recompiling the server.
4) Build it
5) Install it , you need sudo
sudo make install
6) Done, all the Apache http server’s files and folders are located at /usr/local/apache.
Should i install it manually or automatically?
This really depend on your needs, and your expertise. Yum install did all the folders structure and automatically start scripts, put in init.d and many post configuration for you, if you are lazy and not really care about the folder structure, this is definitely the best choice to go. However if you want to customize the Apache folder structure during the installation and need full control of what happened in your machine, the manual ways is what you need. For me.. the lazy yum install is the faster way to go 🙂