How to install xampp on ubuntu 12.04

| | 1 min read

Those who are working on php/achache/msql environment, I feel it is always easier to download and install xampp on your machine compared to separate installation of php/mysql/apache.I. Given below the steps for that.

Downloading xampp latest verion

  1. Download xampp-linux-1.8.1.tar.gz from apachefriends.
  2. Put the file on home/user.
  3. Open terminal.
  4. Give the command

    sudo tar xzvf xampp-linux-1.8.1.tar.gz -C /opt/

xmapp will be installed on /opt/lampp directory.

2. Then to start xampp,

Give the command

sudo /opt/lampp/lampp start

You will be getting the below mentioned message on your terminal

Starting XAMPP for Linux 1.8.1...

XAMPP: Starting Apache with SSL (and PHP5)...

XAMPP: Starting MySQL...

XAMPP: Starting ProFTPD...

XAMPP for Linux started.

3. Stopping xampp

Give command

sudo /opt/lampp/lampp stop

4. Verification of xampp works

For that start xampp first.

sudo /opt/lampp/lampp start

Then open a browser and just give URL,

http://localhost

You will get xampp welcome screen as in the attached screenshot xmpp-welcome-screen.png

xampp-welcome-screen.png

5. Security

To make the xampp secure, you have to set password for xampp pages, mysql/phpmyadmin and mysql root user.

Otherwise when you are trying to access xampp pages, you will get error as in the screenshot error-phpmydmin.png.
error-phpmyadmin.png

So to set password, give command on the terminal,

sudo /opt/lampp/lampp security

and set password accordingly to the instructions showing on the terminal.

Now you can start using xampp

Reference link: http://www.apachefriends.org/en/xampp-linux.html