[rt-users] RE: Can't connect to local MySQL server through socket

Scott McClelland smcclell at vortexdata.com
Thu May 31 14:37:25 EDT 2001


If you can't find mysql.sock anywhere, then mysqld is probably not running.
Try running
shell> mysqladmin version
or just do a find, like this:
shell> find / -name mysql.sock

What I had to do was change /etc/my.cnf to point to the actual location of
the mysql.sock file (which gets created when mysqld starts, and goes away
when the daemon stops), rather than /var/lib/mysql/mysql.sock

The /etc/my.cnf file is explained here:
http://www.mysql.com/doc/O/p/Option_files.html

Here is the new contents of my /etc/my.cnf file:

----------
[client]
port=3306
socket=/tmp/mysql.sock

[mysqld]
port=3306
socket=/tmp/mysql.sock
------------
There is some good documentation at mysql.com, but you have to search for
the specific problem.
http://www.mysql.com/doc/P/o/Post-installation.html

I didn't remember if I kept the RPM, or reinstalled from source (I tried so
many things).  It is an RPM after all:

rpm -q MySQL
MySQL-3.23.36-1

/*------------------------------------------
Scott McClelland, CNE, MCP
Network Administrator
Vortex Data Systems 
http://www.vortexdata.com
--------------------------------------------*/



> -----Original Message-----
> From: Cassie Chang [mailto:CChang at thesupply.com]
> Sent: Wednesday, May 30, 2001 5:09 PM
> To: 'smcclell at vortexdata.com'
> Subject: Can't connect to local MySQL server through socket
> 
> 
> 
> Hi,
> 
> I run into the same problem:
> 
> 1. I can not find my mysql.sock file
>    not in tmp/mysql.sock, and not in /var/lib/mysql/mysql.sock
> 
> 2.  I can not tell what have you changed in the my.cnf file
>     it already has socket=/tmp/mysql.sock there
> 
> Appreciate your help
> Cassie 
> 




More information about the rt-users mailing list