How to install Apache on Linux?

How to install Apache on Linux?

These are some steps to install Apache on Linux. In this guide, you will get commands to install Apache on Ubuntu.

Step 1: Update System

The very first step is to update before installing any packages on Linux, so update your system using this command.

$ sudo apt-get update

Step 2: Install Apache

After Updating the system , you need to run this command to install Apache.

$ sudo apt-get install apache2

Step 3: Control Commands

After installing the Apache Web Server on your system, you can control it using these commands

$ sudo systemctl enable apache2
$ sudo systemctl disable apache2
$ sudo systemctl start apache2
$ sudo systemctl stop apache2
$ sudo systemctl restart apache2
$ sudo systemctl reload apache2

Setup Web Server on Raspberry Pi
Copyright © 2020-2022 Engineer Jagat All rights reserved. Developed by Ravindra Rana