I use Ubuntu 12.04 x64, currently with Mysql 5.5.28 (plus Galera, but I don't think it's related). I made some changes in my.cnf, but changes was related to InnoDB settings (a lot more memory for the buffer pool, flush, thread concurrency settings etc.).
After that when I hit service mysql restart
I cannot enter mysql console - I get following error message:
Lost connection to MySQL server at 'reading initial communication packet',
system error: 104
Sometimes next try results in entering console, sometimes not and I have to restart my SSH connection. What could be the problem and how to fix it?
EDIT:
I noticed that most of the time after the system error: 104
following error occurs:
ERROR 2002 (HY000): Can't connect to local MySQL server through socket
'/var/run/mysqld/mysqld.sock' (111)
After few times it usually starts. Unfortunately now it didn't and in syslog there is:
Error in my_thread_global_end(): 2 threads didn't exit
Restarting SSH connection / MySQL server is not working. I can try reboot server but I'd try to resolve this without that step. Its testing environment so I want to find better solution than restart whole server ;)