Mailing List Archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [tlug] MySQL behaving strangely



TLUG,

Turns out MySQL is not quite as solved as I had hoped. After rebooting since last time it seemed to be fixed, it stopped working again.

I've narrowed down the problem, and even sort of have a solution, but I don't know if it's the right one.

When I boot, all I have to do is run this command:

ln -s /var/run/mysqld/mysqld.sock /tmp/mysql.sock

... and MySQL works fine.

I figured I would edit /etc/mysql/my.cnf so that it said:
socket        = /tmp/mysql.sock

... in all the relevant places. That should eliminate the need for setting up a symlink every time, right?

Turns out, not so. When the /etc/mysql/my.cnf is edited to use /tmp/mysql.sock directly, MySQL won't connect at all. I get all sorts of "Can't connect to database" errors in just about every program that uses MySQL.

So right now it seems like the only solution is to set up a script of some kind that creates the symlink on every boot. But that seems more like a hack than a proper solution.

Is there a better way to do this?

Thanks for any advice.

--
Dave M G
http://tlug.jp/mediawiki/index.php?title=User:Dave_M_G


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links