How to install Apache on CentOS 8

The Apache HTTP server is the most widely used web server in the world. It is a free, open source, and cross-platform HTTP server that contains powerful features and can be extended with many modules.

In this article, we will explain how to install and manage Apache web server on CentOS 8.

One, install Apache

Apache is available in the default CentOS source repository and installation is very straightforward.

In RHEL-based distributions, Apache packages and services are called httpd. To install Apache, use root or another user with sudo privileges and run the following command:

sudo yum install httpd

Once the installation is complete, enable and start the Apache service:

sudo systemctl enable httpd
sudo systemctl start httpd

To verify that the service is running, check its status:

sudo systemctl status httpd

The output looks like this:

● httpd.service - The Apache HTTP Server
 Loaded:loaded(/usr/lib/systemd/system/httpd.service; enabled; vendor preset: disabled)
 Active:active(running) since Sat 2019-10-1215:54:58 UTC; 6s ago
  ...

Second, adjust the firewall##

FirewallD is the default firewall scheme on CentOS 8.

During the installation process, Apache created a firewalld service file using predetermined rules to allow access to HTTP (80) and HTTPS (443) ports.

The following command will permanently open the necessary ports:

sudo firewall-cmd --permanent --zone=public--add-service=http
sudo firewall-cmd --permanent --zone=public--add-service=https
sudo firewall-cmd --reload

Three, manage Apache

This section explains how Apache configuration files are organized and the best practices for managing Apache web servers.

Four, summary##

Congratulations, you have successfully installed Apache on your CentOS 8 system. You are ready to deploy your application and use Apache as a web server or proxy server.

Recommended Posts

How to install Apache on CentOS 8
How to install Apache Maven on CentOS 8
How to install Apache Kafka on CentOS 7
How to install jdk1.8 on centOS7
How to install MySQL on CentOS 8
How to install Memcached on CentOS 8
How to install R on CentOS 8
How to install Virtualbox on CentOS 8
How to install Apache on Ubuntu 20.04
How to install TensorFlow on CentOS 8
How to install TeamViewer on CentOS 8
How to install Perl 5 on CentOS
How to install Git on CentOS 8
How to install Gradle on CentOS 8
How to install Elasticsearch on CentOS 8
How to install Java on CentOS 8
How to install Go on CentOS 8
How to install GCC on CentOS 8
How to install Yarn on CentOS 8
How to install Nginx on CentOS 8
How to install Asterisk on CentOS 7
How to install Jenkins on CentOS 8
How to install Vagrant on CentOS 8
How to install Python 3.8 on CentOS 8
How to install Tomcat 9 on CentOS 8
How to install Webmin on CentOS 8
How to install Ruby on CentOS 8
How to install Apache on Ubuntu 20.04
How to install Skype on CentOS 8
How to install htop on CentOS 8
How to install Elasticsearch on CentOS 8
How to install Postgresql on CentOS 8
How to install Wordpress on Centos
How to install TeamViewer on CentOS 8
How to install MongoDB on CentOS 7
How to install Odoo 13 on CentOS 8
How to install OpenCV on CentOS 8
How to install PHP on CentOS 8
How to install MongoDB on CentOS 8
[Graphic] How to install tomcat on centos
R&D: How To Install Python 3 on CentOS 7
How to install Apache Kafka on Ubuntu 18.04
How to install Apache Maven on Ubuntu 20.04
How to install Apache Tomcat 8 on Ubuntu 16.04
How to install GCC compiler on CentOS 7
How to install offline JDK1.8 on centos7.0
How to install and configure Elasticsearch on CentOS 7
How to install Visual Studio Code on CentOS 8
How to install and use Docker on CentOS 7
How to install RPM packages on CentOS Linux
How to install and use Composer on CentOS 8
How to install and configure Redis on CentOS 8
How to install jdk1.8.0_151 and mysql5.6.38 on centos7.2.1511
How to install and configure phpMyAdmin on CentOS 6
How to install and use Curl on CentOS 8
How to install and configure Owncloud on CentOS 8
How to install VirtualBox client extension on CentOS 8
How to install Docker CE on RHEL 8 / CentOS 8
How to install and uninstall tomcat on centos
How to install and configure Redmine on CentOS 8
How to install Memcached on Ubuntu 20.04