XAMPP: Another web server is already running
Asked Answered
T

12

20

I get the following error after installing gitlab..

root@Blase:~# sudo /opt/lampp/lampp start
Starting XAMPP for Linux 7.0.9-1...
XAMPP: Starting Apache...fail.
[XAMPP:  Another web server is already running.][1]
XAMPP: Starting MySQL...already running.

I cannot access my localhost/phpmyadmin or any projects folder as am redirected to Gitlab.

I tried to view which program is using port 80 by running: "netstat -tulpn | grep --color :80" and i got the output shown in attached image. Any help guys? enter image description here

Teutonic answered 8/11, 2016 at 7:3 Comment(2)
Where is the attached imageValerlan
nginx is already running on that port. GitLab uses nginx in an omnibus installation. Where exactly is the problem?Doggoned
L
89

I had to stop all the services,

$sudo /etc/init.d/apache2 stop

$sudo /etc/init.d/mysql stop

$sudo /etc/init.d/proftpd stop

Then I restarted the server

sudo /opt/lampp/lampp restart
Loxodrome answered 5/6, 2017 at 22:11 Comment(0)
H
13

**Running Server on Linux Ubuntu **

In my case Nginx server is already running that's why i am getting this kind of error.

I stop the Nginx Web server first then start Apache server.

Stop Nginx server

sudo systemctl stop nginx

Start Apache Server

sudo /opt/lampp/lampp start

Must Read

Sometimes it can be port conflict between web servers. Changing the port number of both server or maybe one server we can run both servers at a time.

Hygrograph answered 12/2, 2020 at 6:36 Comment(0)
P
12

I face this problem then I stop LAMP services.

sudo service apache2 stop
sudo service mysql stop

then check these services has stopped

sudo service apache2 status
sudo service mysql status

then run xammp and try start MySQL server and apache server

Puddle answered 18/11, 2020 at 18:58 Comment(0)
P
6

The most possible reason why your Xampp server is not running is that you might have installed Xampp and apache2 simultaneously or MySQL server. So in order to work with Xampp server, you have to stop the Apache2 and MySQL.

$sudo /etc/init.d/apache2 stop

$sudo /etc/init.d/mysql stop

And then restart Xampp server

$sudo /opt/lampp/lampp restart
Phosphide answered 13/11, 2018 at 5:25 Comment(0)
W
3

If when starting Apache server XAMPP responds "Another web server is already running", run this command: sudo netstat -nap | grep :80

you will see something like tcp6 0 0 :::80 :::* LISTEN 1078/apache2

then run sudo kill 1078 - in my case 1078 (in your case probably another number)

Wernick answered 28/1, 2020 at 8:24 Comment(0)
S
2

You only need to stop Apache2

$sudo /etc/init.d/apache2 stop

then you may restart lampp

$sudo /opt/lampp/lampp start

Link to pic of an illustration

Stonework answered 24/3, 2019 at 4:37 Comment(0)
B
1

sudo apachectl stop then starting apache web server from xampp manager worked for me.

Bioscopy answered 10/5, 2022 at 10:16 Comment(0)
D
0

I had a similar issue. If I stop apache2 using:

$sudo /etc/init.d/apache2 stop

the issue persists, refer to this site: https://askubuntu.com/questions/170640/how-to-disable-apache2-server-from-auto-starting-on-boot.

Donato answered 13/9, 2018 at 21:9 Comment(0)
A
0

I experienced this issue using ubuntu 18.04, but all the solutions I found here did not solve my problem. So I want to share what I did so that it might help others as well.

go in the /etc folder in the root file system, and delete the Apache2 folder. Xampp has it's apache in the opt/lampp directory, so the Apache in the etc folder conflicts since this one starts at startup. To access these folders, use the command $sudo nautilus

Aleph answered 18/9, 2019 at 7:20 Comment(0)
A
0

You can add convenient aliases to:

alias xampp-start='sudo /etc/init.d/apache2 stop && sudo /opt/lampp/lampp start'
alias xampp-stop='sudo /opt/lampp/lampp stop'
alias xampp-restart='sudo /opt/lampp/lampp restart'
alias xampp-gui='sudo /etc/init.d/apache2 stop && sudo /opt/lampp/manager-linux-x64.run'
Aulea answered 3/3, 2020 at 6:7 Comment(0)
M
0

If still not resolved. please check this link.

It helped me.

This is the part that really solved my problem to stop the server that was running earlier.

Solved by running this on terminal

sudo netstat -nap | grep :80

You’ll see apache2 and there is 3–4 digit numbers before it, mine is 980

sudo kill [number]

where [number] is the number for apache2, in this case I run sudo kill 980

*The number might be different than yours.

Start XAMPP again.

cd /opt/lampp/ && sudo -s

./lampp start

I hope this is helpful

Macguiness answered 18/5, 2021 at 10:29 Comment(0)
M
0

What worked for me:

  1. Execute comand ps aux | grep mysql in terminal and find the _mysql process from XAMPP. In my case:

    _mysql 9092 0,0 0,4 34422708 61904 s000 S 9:39AM 0:03.23 /Applications/XAMPP/xamppfiles/sbin/mysqld --basedir=/Applications/XAMPP/xamppfiles --datadir=/Applications/XAMPP/xamppfiles/var/mysql --plugin-dir=/Applications/XAMPP/xamppfiles/lib/mysql/plugin/ --user=mysql --log-error=/Applications/XAMPP/xamppfiles/var/mysql/MBP-Enrique.local.err --pid-file=/Applications/XAMPP/xamppfiles/var/mysql/MBP-Enrique.local.pid --socket=/Applications/XAMPP/xamppfiles/var/mysql/mysql.sock --port=3308

  2. Kill that process using its id: sudo kill -9 [id]. In my case: sudo kill -9 9092.

  3. Restart XAMPP: sudo /Applications/XAMPP/xamppfiles/xampp restart.

  4. All three servers start correctly this time.

Many answered 5/3 at 9:17 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.