mysql not working on xammp [duplicate] - php

This question already has answers here:
xampp MySQL does not start
(12 answers)
Closed 8 years ago.
please help me ....whenever i start xammp server and trying to start mysql It gives an error
like...
4:42:52 PM [mysql] Problem detected!
4:42:52 PM [mysql] Port 3306 in use by ""C:\Program Files\MySQL\MySQL Server 5.1\bin\mysqld" --defaults-file="C:\Program Files\MySQL\MySQL Server 5.1\my.ini" MySQL"!
4:42:52 PM [mysql] MySQL WILL NOT start without the configured ports free!
4:42:52 PM [mysql] You need to uninstall/disable/reconfigure the blocking application
4:42:52 PM [mysql] or reconfigure MySQL and the Control Panel to listen on a different port

In a command shell, run:
netstat -b -p TCP
and look for a line that says localhost:3306 in the second column. Below this is the application's name using the port.

U probably have an application using the same port, if you have skype(mine was) you should consider turning off the automatically start on it to free the port. Run services.msc to check.

Related

Port problems installing XAMPP

Hello I am installing XAMPP and I am having a problem with MySQL port 3306.
I have used the control panel config my.ini and changed the port settings to 3307 and it is still showing the following error:
22:48:55 [mysql] Problem detected!
22:48:55 [mysql] Port 3306 in use by "C:\Program Files\MySQL\MySQL Server 5.7\bin\mysqld.exe" --defaults-file="C:\ProgramData\MySQL\MySQL Server 5.7\my.ini" MYSQL57"!
22:48:55 [mysql] MySQL WILL NOT start without the configured ports free!
22:48:55 [mysql] You need to uninstall/disable/reconfigure the blocking application
22:48:55 [mysql] or reconfigure MySQL and the Control Panel to listen on a different port
on Windows+R write cmd and press enter
on command line write:
netstat -nap tcp
and press enter, LISTENING are port used, search for 3307
for view name process use (execute how administrator):
netstat -nabop tcp

MySQL won't start on xampp (Windows)

This problem started when I didn't properly hibernate my laptop. Every time I open xampp, I can't start MySQL. I searched for online answers but nothing happened. I tried changing the port from 3306 to 3307 to 80, still nothing happened.
So I uninstalled xampp and install it again. After installing, I tried to start Apache and MySQL. Worked fine with Apache but on MySQL, I got this error log:
4:52:15 PM [mysql] Error: MySQL shutdown unexpectedly.
4:52:15 PM [mysql] This may be due to a blocked port, missing dependencies,
4:52:15 PM [mysql] improper privileges, a crash, or a shutdown by another method.
4:52:15 PM [mysql] Press the Logs button to view error logs and check
4:52:15 PM [mysql] the Windows Event Viewer for more clues
4:52:15 PM [mysql] If you need more help, copy and post this
4:52:15 PM [mysql] entire log window on the forums
It's usually because of Skype (or any other program that uses MySql port). Go to Skype Options > Advanced > Connection type in alternative port (e.g. 42795) and uncheck "Use port 80 and 443..."

MySQL startup error - port is already in use

I get the following error while trying to start XAMPP:
12:34:26 PM [mysql] Attempting to start MySQL service...
12:34:38 PM [mysql] Problem detected!
12:34:38 PM [mysql] Port 3306 in use by ""C:\Program Files\MySQL\MySQL Server 5.1\bin\mysqld" --defaults-file="C:\Program Files\MySQL\MySQL Server 5.1\my.ini" MySQL"!
12:34:38 PM [mysql] MySQL WILL NOT start without the configured ports free!
12:34:38 PM [mysql] You need to uninstall/disable/reconfigure the blocking application
12:34:38 PM [mysql] or reconfigure MySQL and the Control Panel to listen on a different port
12:34:38 PM [mysql] Attempting to start MySQL service...
The log cleraly states that another application is listening on port 3306, so it is not possible to start MySQL since 3306 is the configured port for it (default port for MySQL connections). This application that already listens on por 3306 is another instance of MySQL that's probably configured to start automatically.
If you are using Windows, click the Start button, then Execute, then type services.msc and press [Enter]. Look for the running MySQL service, stop it, and configure it to prevent its launching on system startup. After that you should start XAMPP normally.
open xampp control panel.
click on "config" button.
click on "service and port settings".
click on "mysql" tab.
change the value labeled "Main Port" to 3307
So, mysql is listening 3306 port by default. According to your error,some service has already used it.
Depends on your OS,check who are using it. For example for netstat -lp | grep 3306, you can close this service and restart your mysql or change to another port OR you an change mysql default port to listen in your my.cnf file.
may be you have previously installed xampp app and left in before complete installation and then reinstalled it before uninstalling previous one just uninstall privious one or uninstall both and reinstall
Well my friend told me to reinstall xampp in C drive and it did worked but after some time i was facing same problem again so i followed this steps hope it will be helpfull.
Open cmd as administrator
If there's nothing important running on port number 3306 kill that process.
enter image description here
Follow this steps:
(In case photo have any error)
after opening cmd as administer run command
netstat -ano |findstr 3306
Then observe the PID at last column if there is only one process running shut it down.
taskkill /F /PID portidnumber
In case you get error even after doing that try to do follow the steps here:
I experienced that if we try to stop mysql before apache it is giving error.
So when you go to stop process or server stop apache first and then mysql.
And don't shutdown xampp without stopping any server
(I found this by web search and some try and error and it's working for me at least)

Unable connect to MySql in Xampp server

here I am trying to connect mysql in xampp server but getting this message again and again.... I am able to connect apache.
Problem detected!
11:59:20 PM [mysql] Port 3306 in use by ""C:\Program Files (x86)\MySQL\MySQL Server 5.1\bin\mysqld" --defaults-file="C:\Program Files (x86)\MySQL\MySQL Server 5.1\my.ini" MySQL"!
11:59:20 PM [mysql] MySQL WILL NOT start without the configured ports free!
11:59:20 PM [mysql] You need to uninstall/disable/reconfigure the blocking application
11:59:20 PM [mysql] or reconfigure MySQL and the Control Panel to listen on a different port
11:59:20 PM [mysql] Attempting to start MySQL service...
Please help me. Thanks in advance.

Apache service is not getting started , 80 port blocked or used [duplicate]

This question already has answers here:
XAMPP - Port 80 in use by "Unable to open process" with PID 4! 12
(27 answers)
Closed 8 years ago.
Suddenly i faced the above issued mentioned in the title , I clicked on the start service in xamp software for starting of with Apache sever but i couldnt , Below is what the error was throw up with
Problem detected!
5:55:26 PM [Apache] Port 80 in use by "Unable to open process" with PID 4!
5:55:26 PM [Apache] Apache WILL NOT start without the configured ports free!
5:55:26 PM [Apache] You need to uninstall/disable/reconfigure the blocking application
5:55:26 PM [Apache] or reconfigure Apache and the Control Panel to listen on a different port
And Yes i have tried methods ,Event i can't find web development agent in services msc
I don't know what to do , A help will be great .
You've got a program running on port 80 already, so apache cant bind to that port,
Skype is one of those programs, tell Skype to use a different port in it's settings, or simply close it.
If its not skype try running: netstat -a -b in console (cmd) to see what program is using port 80, then close it.
You could also run resmon.exe as this has an easier interface.
In same cases, the software like Skype will automatically take Port 80. try to change port or uninstall it.
if it is port issue, go to ms dos and follow this
NETSTAT [-a] [-e] [-n] [-s] [-p proto] [-r] [interval]
-a Displays all connections and listening ports.
-e Displays Ethernet statistics. This may be combined with the -s option.
-n Displays addresses and port numbers in numerical form.
-p proto Shows connections for the protocol specified by proto; proto may be TCP or UDP. If used with the -s option to display per-protocol statistics, proto may be TCP, UDP, or IP.
-r Displays the routing table.
-s Displays per-protocol statistics. By default, statistics are shown for TCP, UDP and IP; the -p option may be used to specify a subset of the default.
interval Redisplays selected statistics, pausing interval seconds between each display. Press CTRL+C to stop redisplaying statistics. If omitted, netstat will print the current configuration information once.

Categories