apache tutorial - Install Apache:Linux Platform - apache - apache web server - apache server - apache2




On Red Hat or rpm based systems

  • If you are using an rpm (RedHat Package Manager is a utility for installing application on Linux systems) based Linux distribution i.e. Red Hat, Fedora, CentOs,
  • Suse, you can install this application by either vendor specific Package Manager or directly building the rpm file from the available source tarball.
  • You can install Apache via the default Package Manager available on all Red Hat based distributions like CentOs, Red Hat and Fedora.
[[email protected] ~]# yum install httpd
click below button to copy the code. By Apache tutorial team

The apache source tarball could be converted into an rpm file using the following command.

[[email protected] ~]# rpmbuild -tb httpd-2.4.x.tar.bz2
click below button to copy the code. By Apache tutorial team

It is mandatory to have -devel package installed on your server for creating .rpm file from source. Once you convert the source file into an rpm installer, you could use the following command to install Apache.

\[[email protected] ~]# rpm –ivh httpd-2.4.4-3.1.x86_64.rpm
click below button to copy the code. By Apache tutorial team
  • After the installation the server does not start automatically, in order to start the service, you have to use any of the following command on Fedora, CentOs or Red Hat.
[[email protected] ~]# /usr/sbin/apachectl start

[[email protected] ~]# service httpd start

[[email protected] ~]# /etc/init.d/httpd start
click below button to copy the code. By Apache tutorial team

Related Searches to install apache linux apache