Hi, Are you searching on How to install LAMP Stack on Ubuntu 20.04 ? Then, I am here to help you on How you can install LAMP Stack. Follow along and you will know how to do so.
In that article, I will give you a complete guide to setup LAMP Stack on your local machine. A LAMP Stack is the software stack of Linux Operating System, Apache HTTP Server, MySQL Relational Database Management System, and PHP Programming Language(LAMP) which is the foundation for the Linux hosted Websites and Web Applications. Now, I will show you How to install LAMP Stack on Ubuntu 20.04 LTS.
The layer of LAMP Stack consists of free and open-source products i.e. Linux, Apache, MySQL, and PHP.
- Linux – Operating System hosting the Applications.
- Apache – Apache HTTP Server is a free and open-source cross-platform web server.
- MySQL/MariaDB – Open Source Relational Database Management System.
- PHP – Programming/Scripting Language used for developing Web Apps.
Here are the minimum system requirements to install and run the LAMP stack in Ubuntu 20.04 LTS.
- RAM: Minimum 1GB memory
- HDD: At least 1 GB Free Disk Space
- CPU: 1 Core Processor
There are several variants of this model as well. There is also much alternative software replacing the LAMP Stack. Some examples of those alternatives are:
XAMPP – Operating System, Apache, MySQL/MariaDB, PHP + Perl
WAMP – Windows, Apache, MySQL & PHP
WISA – Windows, IIS, SQL & ASP.net
MAMP – Mac OS, Apache, MySQL & PHP
Read More : How to install WordPress on localhost via XAMPP
Install LAMP Stack on Ubuntu 20.04 LTS
Step 1: Updating and upgrading your System
First of all, we will update the package database of packages needed for the system using the following command which requires superuser privileges, so you’ll need to use sudo:
$ sudo apt-get update
then, we will fetch the new version of packages existing on the machine using the following command:
$ sudo apt-get upgrade
Step 2: Install Apache Server
After our system is upgraded to the latest packages, we will now install the Apache Server in our system. To install the Apache package in Ubunutu, use the command:
$ sudo apt-get install apache2
now, verify that the Apache server was installed correctly, open the web browser and hit the following URL in the address bar:
Apache Server Controls:
To have control over the Apache server in the system, systemctl commands can be used with a series if switches:
Stop Apache Server:
$ sudo systemctl stop apache2.service
Start Apache Server:
$ sudo systemctl start apache2.service
Restart Apache Server:
$ sudo systemctl restart apache2.service
Reload Apache Server:
$ sudo systemctl reload apache2.service
Step 3: Install MySQL
Official Ubuntu Book
The free Ubuntu operating system has won the hearts and minds of millions of users worldwide. It combines a strong technical platform, impressive quality, and an enthusiastic global community of users who relentlessly support, document, and test it.