November 24, 2020
How to install apache on Ubunt 18.04

How To Install Apache Web Server on Ubuntu 18.04 LTS

The Apache HTTP Server (“httpd”) was launched in 1995 for the first time and it has been the most popular web server on the Internet since April 1996 . The Apache HTTP Server is developed and maintained by Apache Software Foundation. Apache HTTP version 2.4.x is the latest release and the most stable so far. There are many new features in Apache HTTP version 2.4.x, namely : core enhancement, new modules, modules enhancement and program enhancement.

In this article we will expalain how to install the Apache HTTP Web Server on Ubuntu 18.04 LTS. The last stable release of Apache is version version 2.4.41, but on this article we are using Apache version 2.4.29.

Apache Web Server Installation Steps

There are several steps in installing Apache web servers on Ubuntu, as summarized below :

  1. Update Ubuntu Repo
  2. Install Apache Web Server
  3. Verify Apache Web Server

Update Ubuntu Repesitory

It is ussually in Ubuntu environment, if we are going to install new application, we have to update the Ubuntu software repository first. The usage of this activity is to ensure all the software we want to install is the newest version and has been validated by the community. For this purpose, we must have root privilege, we can using sudo in every single command, or we loged in to the root user first as below.

ramans@ubuntu:~$ sudo su -
[sudo] password for ramans: 
root@ubuntu:~# apt update
update ubuntu repository
Update Ubuntu repository

Install apache web server

After all our Ubuntu software was updated, the next step is Apache installation process.

install apache2 on Ubuntu 18.04 TLS

Verify the Apache Installation

After all installation process was completed done, the next step is to veryfy if the Apache web server has installed properly done. This step could be achieved with generic Linux Ubuntu command.

root@ubuntu:~# systemctl status apache2

The status is as screenshot below :

Showing Apache 2 status

Verifying the Apache web server status could be done also by hitting the server’s IP address via browser. To know the right server’s IP Address, just the the command below :

root@ubuntu:~# hostname -I 
192.168.59.141 

In my environment, the IP address is 192.168.59.141, and the Apache web server for Ubuntu has been showing.

Apache2 Ubuntu Default Page

After this installation is completed, we could perform any task fitted with our requirement. For the example, if weant to build the virtual domain.

Share this article via :

2 thoughts on “How To Install Apache Web Server on Ubuntu 18.04 LTS

Leave a Reply

Your email address will not be published. Required fields are marked *