Friday, Sep 09, 2022 / Ubuntu / Girish Panchal

Here’s Everything About Setting LAMP Installations in Ubuntu

Setting LAMP Installations in Ubuntu

When it comes to installation and setting up a development environment, you need to be very prepared with all the technicalities and expert programmers by your side to handle everything with ease.

However, if you are dealing with some sort of problems or confusion regarding setting up a LAMP ((Linux + Apache + MySQL + PHP) with Ubuntu, then we have got you covered!

In this comprehensive guide, we will be covering everything about installation to help you ease down your tasks and set up everything smoothly.

Without any further ado, let’s get started!

Here’s little something about Ubuntu & LAMP!

Ubuntu is a Linux-based operating system. As the manager of Ubuntu, Canonical is responsible for releasing a new Ubuntu version every six months. Canonical also provides hosting servers for Ubuntu Community, allowing people worldwide to contribute to testing software bugs, and give technical support for free. Recently Ubuntu released 22.04 LTS (Jammy Jellyfish), and it is more powerful as compared to previous versions.

LAMP installations (Linux + Apache + MySQL + PHP) are a popular setup for Ubuntu servers. There is a plethora of Open Source applications written using the LAMP application stack. Some popular LAMP applications are Wiki’s, Content Management Systems, and Management Software such as phpMyAdmin.

One advantage of LAMP is the substantial flexibility for different databases, web servers, and scripting languages. Popular substitutes for MySQL include PostgreSQL and SQLite. Python, Perl, and Ruby are also frequently used instead of PHP. While Nginx, Cherokee, and Lighttpd can replace Apache.

Which packages & software need to install for Ubuntu installation?

There are a few packages that must be installed on Ubuntu in addition to LAMP in order for it to work with any open-source application.

The recommended software for the Ubuntu installation is as follows –

  1. Phpmyadmin – The interface to work with MySql
  2. Composer – Package manager
  3. Nodejs/NPM – NPM package manager
  4. Git – Version control
  5. ZIP, Unzip – Compress and Extract files and folders
  6. Dukto – Sharing a file in the local network
  7. Code Editor – We prefer Sublime and VS code
  8. Filezilla – To work with FTP/SFTP

Setting up LAMP with Ubuntu!

Before configuring LAMP with Ubuntu, you must comprehend what shell scripting is.

Shell script: A shell is a command-line interpreter, and typical operations performed by shell scripts include file manipulation, program execution, and printing text.

We put up a LAMP setup along with a few other programs with the aid of a Shell script.

Ubuntu package installation is a time-consuming operation that requires some familiarity with the Ubuntu operating system. Additionally, Ubuntu application software offers a few packages that may be installed using the Ubuntu interface and are necessary to use PHP open source.

In accordance with the above request, we have produced a shell script (https://github.com/krishaweb/dev-environment-bash/blob/main/development-env.sh) aids in package installation using a single command. The shell script starts when the root user is logged in to the system.

It helps save time to find the appropriate command and run it on your machine to manually install packages and some configurations. Also, you do not require higher expertise to install packages using the development environment.

You only need to keep an eye on things and set the necessary package’s username and password.

Here is the command to RUN to shell script

  1. Open the Terminal application on Linux
  2. Need to check the .sh file permission
  3. Set execute permission using the chmod command if the file is not executable. chmod +x script-name-here. sh
  4. To run shell script file:

./script-name-here.sh

Another option:

sh script-name-here.sh

OR

bash script-name-here.sh

When you run this script, some versions can be different depending on your Ubuntu version because Ubuntu has an inbuilt capacity to get versions based on the ubuntu version. The shell script’s lack of versioning is the cause.

The main issue is with Ubuntu 22.04 LTS. In this situation, installing PHPMyAdmin 4.9.* and adding multiple PHP versions to manage the PHP package would be my preference. To handle the various MySQL versions, I added a further command to the script. When you run a script, MySQL version 5.7.* would be installed. By enabling and disabling a few commands on the script itself, you can manage the MySQL version.

To conclude –

Congratulations, you have successfully done it. Here’s a wrap on a complete tutorial about setting up LAMP installation with Ubuntu. We hope it will help you out! For more information about it or if you are seeking expert guidance, then you can reach out to us & our team of developers will surely assist you further.

To contact us,  Click Here

divider
author
Girish Panchal
under Ubuntu
Landing Page Optimization Tips and Best Practices

Complete Guide to Landing Page Optimization

Landing Page Optimization Resource

Inbound Marketing Basics for Small Businesses

Inbound Marketing for small business - Cover page
line

You have a visionWe know the way to get you there.