|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
ERROR 2002: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.
i have mysql installed on suse 8.2 but when i try to run mysql i get
ERROR 2002: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (111) i did "ps -a|grep mysql" and noticed the mysql daemon was not running. i tried starting it with safe_mysqld but i get mysqld ended.It does not start. what am i doing wrong i have installed mysql 3.23.55-20 mysql-client 3.23.55-20 mysql-shared need i install the mysql-bench too? |
|
#2
|
|||
|
|||
|
i got the solution to my problem all i did was
chown -R mysql /var/lib/mysql/* chgrp daemon /var/lib/mysql/* and all worked fine |
|
#3
|
|||
|
|||
|
Thanks! Its now working. But can u explain me why its working now. Why I can't use mysql user as a mysql group.
Thanks, Kallol HRC Techonologies Limited Quote:
|
|
#4
|
|||
|
|||
|
Soultion not working for me Error 2002
Quote:
Hi I am having the same problem and when I tried your fix I bot the reply: g4:~ rosemarielanaro$ chown -R mysql /var/lib/mysql/ chown: /var/lib/mysql/: No such file or directory g4:~ rosemarielanaro$ chgrp daemon /var/lib/mysql/ chgrp: /var/lib/mysql/: No such file or directory I have no clue either I am really new at this and need to get mysql up and running quickly to learn how to develop databases any help would be greatly appreciated. Thanks Rose ![]() |
|
#5
|
|||
|
|||
|
Hi!
It looks like that you have forgotten the "asterix" *. you should try it exactly as collins23 suggested: chown -R mysql /var/lib/mysql/* chgrp daemon /var/lib/mysql/* Hope that was your problem kd Quote:
|
|
#6
|
|||
|
|||
|
pls help, I have no clues
![]() I have this problem Code:
Error Number: 2002 Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) Now, I have read the above posts and I used phpMyAdmin to enter chown -R mysql /var/lib/mysql/* chgrp daemon /var/lib/mysql/* Am i doing this in the wrong place because I get this error: Code:
#1064 - You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'chown - R mysql / var / lib / mysql/* chgrp daemon /var/lib/mys |
|
#7
|
|||
|
|||
|
i have this same problem - the command does not work as the error invalid user is returned? Any1 got any ideas im running mysql on linux suse -pardon my ignorance (im new 2this) but this should bear no relevance surely?
![]() |
|
#8
|
|||||
|
|||||
|
Quote:
For all of you that get a similar message like: Quote:
So, even before you open a client (for instance PHPMyAdmin), try the chown/chgrp But on the other hand: If you DO get a Quote:
So there should not be a problem. If there (still) is: please post the exact message and when you got the message, i.e. what you did just before you got the message. |
|
#9
|
|||
|
|||
|
Had this problem a few time, solved it but did not know how. Forced the problem again last night and this is how it worked for me.
Reloaded Mysql 4.0, then as root did a search for mysql*. Went into "properties" of every thing it found and changed the owner to my username and the group to "users". That solves any access permission problems. I then open usr/sbin/ as user (now owner) and ran ./mysqld in the terminal..... and it worked. Last, I went into Mysqlcc as user and checked that I had global permissions. Let me know if this helps. It may be not the "professional" way to solve the problem, and may be its opens up other security difficulties. But as I'm only playing with Mysql at the moment I don't mind. Have fun ![]() |
|
#10
|
||||
|
||||
|
You made yourself the owner?
Do you mean Root, or your userid? It might be better to make a new account, named mysql, and have them as the user. This could make it less confusing for other users. Then again, if you're the only user of your box, and simply use it as a testing box, I guess any solution would do =) I've found in the past, this problem was due to a faulty installation. Generally, the person forgot to run the install script as root... |
|
#11
|
|||
|
|||
|
Quote:
This problem (error2002) came to me after PowerSupply shock (no UPS available). Afer restart MYSQL was gone.I am novice in Linux but your solutions were very usefull ! |
![]() |
| Viewing: Dev Articles Community Forums > Databases > MySQL Development > ERROR 2002: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql. |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|