How To Install XAMPP On Linux 32-bit Or 64-bit


In this tutorial we will learn how to Install XAMPP Server On Linux distributions.

Install XAMPP Server

Step 1: Open your favourite web browser and goto the official web page of XAMPP, i.e.


Step 2: Now, click XAMPP for linux.

You may have to click Save File / select the directory you want to select as your Save location before proceeding.

Step 3: Allow the download to complete.

OR

If you want to download XAMPP 5.6.20 32-bit version for Linux, please download it from the link given below:


Once XAMPP installation file finishes downloading onto your computer system, you can proceed.

Step 4: Now, open Terminal (ctrl+alt+t) and change over to the Downloads directory.

Type in cd ./Downloads/ and press Enter.

If your default downloads location is in a different directory, you'll have to change the directory to that folder.

Step 5: Make the downloaded file executable.

Type in $sudo chmod +x xampp-linux-x64-7.4.4-0-installer.run and press Enter.

If you download a different version of XAMPP (e.g. Version 5.6.20), you'll replace 7.4.4 with your XAMPP version's numbers.

Step 6: Now, enter the Installation Command in Terminal.

Type in, $sudo ./xampp-linux-x64-7.4.4-0-installer.run and press Enter.

Step 7: Enter your sudo password when prompted.

Type in the Password you use to Log into your Linux System and then press Enter.

Step 8: Once the Installation Window appears, do the following:

i. Click Next three times.
ii. Uncheck the Learn more about Bitnami for XAMPP.
iii. Now, click Next button.
iv. Then click Next again to begin installing XAMPP.

Step 9: Uncheck the Launch XAMPP box.

Since XAMPP needs a few extra steps to actually run on Linux, you'll need to Finish the Installation without automatically running XAMPP.

Step 10: Click Finish button.

Doing so will close the installation window. At this point, you are ready to run XAMPP.

Running XAMPP

Step 1: Open a New Terminal (ctrl+alt+t).

Note: XAMPP doesn't have any desktop file, so you'll need to launch it from within its Installation directory, via Terminal each time you want to run it.
Step 2: Switch the XAMPP Installation directory.

Type in, $cd /opt/lampp/ and press Enter.

Step 3: Enter the Open Command.

Type in, $sudo ./manager-linux-x64.run or $sudo ./manager-linux.run for 32-bit Linux O/S and press Enter.

Step 4: Now, enter your sudo password when prompted.

Type in the Password you use to Log into your Linux System and then press Enter.

Step 5: Now, click Manage Servers tab.

Step 6: Click Start all or start the Server you want to start by clicking on Start button.

Step 7: Now, open your favourite Web browser and type localhost/ in the address bar of the Web browser.

If the XAMPP Server page display, the XAMPP Server is installed properly in your Linux O/S.

Fix Apache Server Port 80 Problem in Linux

On some Linux Computer Systems, Apache Server won't run due to a blocked port. This can happen for a couple of reasons, but there is a relatively easy fix. Please follow the steps given below:

1. Open a New Terminal (ctrl+alt+t).

2. Switch the Apache2 directory.

Type in, $cd /etc/apache2/ and press Enter.

3. Now, edit the ports.conf file using gedit text editor.

Type in, $sudo gedit ports.conf and press Enter.

4. Enter your sudo password when prompted.

Type in the Password you use to Log into your Linux System and then press Enter.

5. In ports.conf file, search Listen 80 (you can press ctrl+f and type in listen 80 to find it faster).

6. Replace 80 with any open port (e.g. 81/9080).

7. Now, Save this file and Close it.

8. Now, Restart the Apache Server.

Type in, $service apache2 restart and press Enter.

If the Apache Server still not working, then follow the steps given below:

1. At first you can try the following two statements for Apache Server:

$sudo service apache2 status and press Enter

$sudo service apache2 stop and press Enter

2. Even after this, if it doesn't work, then your port (mostly 80) is busy with some other process and to see the process on the port 80: type the following command in the Terminal:

$sudo netstat -lpn |grep :80 and press Enter

3. If the port 80: is busy with some other process, then we have to kill the process in order for Apache Server to work. Type the following command in the Terminal:

$sudo kill sudo lsof -t -i:80 and press Enter

And then XAMPP Apache Server should finally work and it can be verified by viewing localhost/ or phpmyadmin/.



Previous: How To Install XAMPP On Windows 32-bit Or 64-bit