I don't know if you have fixed this probelm, but I had the same problem on Red Hat 
7.0. I had installed the rpm files from MySQL.com and RedHat.com. The problem was 
solved by doing the following.

chmod 755 the "mysql" directory that contains the "mysql.sock" file. 

I am currently running the latest release of MySQL Server & Client. 

Don't take this advice as perfect. I am a newbie also.

Mike,



"bobit" <[EMAIL PROTECTED]> wrote ..
> Hi - here's my prob and background info.  Tried the fix - it didn't work.
> 
> MySQL Connection Failed: Can't connect to local MySQL server through socket 
>'/var/lib/mysql/mysql.sock'
> (111)
> 
> Any thoughts...? 
> 
> 
> I'm not sure if it's the same problem but here goes:
> 
> I just did a fresh install of RH 7.0 with apache, php, and mysql.
> 
> I had the same problem.
> All I had to do was change the permissions on my MySQL directory (in your case 
>"/var/lib/mysql")
> so that my apache user (the user/group that apache runs as) has access.
> 
> check to make sure it also changes permissions on the mysql.sock file.  That's the
> important one.
> 
> I believe apache only needs read (maybe execute) access.
> 
> chmod 755 /var/lib/mysql
> 
> (that's from memory, but you know the gist of the problem)
> 
> 
> 
> 
> Groan..I knew linux was tough but I didn't think I needed a black belt.  I've got
> exactly the same prob after a straight redhat7 install.  I tried to take milner's
> advice and:
> 
> changed the /var/lib/mysql/mysql.sock to 755 for root who I'm logged in as.  Then
> tried to do the same thing for the Mysql directory.  It won't change.  Tried a 
>re-boot.
> 
> Then figured there was something screwy with the directory.
> 
> Moved mysql.sock to /test
> rmdir mysql
> mkdir mysql
> copied the file back in.  The file now had rw permissions only.  But in the test
> dir root had all the permissions to it.  Is it being blocked higher up in the tree.
> 
> My linux book isn't very good on dir permissions.  Will chmod change these even if
> the directory is not empty.
> 
> And how do u list permissions to a directory?  ls -l only seems to work for files.
> 
> In the error log in the same directory I also get:
> 
> mysql.host doesn't exist - but this may be a susequent error.
> 
> I'm a complete newbie so any help would be greatly appreciated.
> TIA
---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to