LAMP (Linux, Apache, MySQL and PHP) is an open source Web development platform that uses Linux as operating system, Apache as the Web server,MySQL as the relational database management system and PHP as the object-oriented scripting language.

Apache2 installation

Install apache2 using the following command:

sudo apt-get install apache2

to check that Apache has been installed without problems, go to your browser and type http://localhost or from remote machine http://serveripaddress/

Note:- You can find your server ip address using ifconfig command.

If everything is correct you will see the message

It works

PHP5 Installation

Install php5 using the following command:

sudo apt-get install php5 libapache2-mod-php5

restart apache2 using the following command:

sudo etc/init.d/apache2 restart

MySql Installation

To install MySql type the command

sudo apt-get install mysql-server

During the installation you will get the screen to set root password for MySql, enter your password and retype it.

Phpmyadmin Installation

phpMyAdmin is a free software tool written in PHP intended to handle the administration of MySQL over the World Wide Web. phpMyAdmin supports a wide range of operations with MySQL. The most frequently used operations are supported by the user interface (managing databases, tables, fields, relations, indexes, users, permissions, etc), while you still have the ability to directly execute any SQL statement.

Install phpmyadmin in ubuntu with the following command:

sudo apt-get install phpmyadmin

During the installation a blue screen will appear asking you which server you want to use apache, apache2 …. choose then apache2 and click ok

Now Point your browser to: http://serverip/phpmyadmin and you should see a login prompt.

That’s it!