I have recently installed 5.5.28-29.2 Percona Server (GPL), Release 29.2 in a Ubuntu 12.04 OS Desktop. I have tried to stop the server using different methods:
-
This might not apply to this particular problem but here it goes anyways. I checked the error log ("/var/log/mysql/error.log") and saw that "explicit_defaults_for_timestamp=TRUE" was causing an error ("Unknown variable"). So I removed it from my.cnf ("/etc/mysql/my.cnf"), and ran "sudo start mysql" and it was back up and running. I hope this helps as well!
I was having this exact same problem. Running the kill
command would kill the process, but in my case it would keep popping up again under a different process ID.
The only way I could figure out how to stop it for good was this:
sudo stop mysql
Hope that helps.
Source: http://www.itfromscratch.com/how-to-stop-the-percona-mysql-server/
Want to kill all mysql instances? Try as root:
pkill mysqld;
For those looking at this years after the fact, I had a similar issue and just solved it.
Seems there was a second init script called orig_mysql.conf that existed in the /etc/init directory along with the mysql.conf file. This caused upstart to start two instances and apparently it got confused when one was ended. As such a continuous respawning took place.
My solution:
service mysql stop
telinit u
Once you confirm you have no mysqld processes running and that they are not respawning any longer, restart mysql with service mysql start
.
Hope this helps someone. It took me two years to solve this.
Using sudo service mysql stop
worked for me.
I'm using Homebrew on Mac OS. brew services stop mysql
did not work for me, but sudo brew services stop mysql
did.