Mike Mapsnac wrote:

I got such error message

ERROR 2002: Can't connect to local MySQL server through socket '/var/lib/
mysql/mysql.sock' (111)

Thanks

Right.
This means that you're using the mysql command-line tool, and it's trying to talk to MySQL through the /var/lib/mysql/mysql.sock file, but can't - probably because the file doesn't exist.


As to why the file doesn't exist ... who knows? Maybe you haven't started the MySQL server yet. What does 'ps ax' show? You should have some 'mysqld' processes running. If not, try starting MySQL, either with the init script ( mine is in /etc/init.d/mysql and can be started with '/etc/init.d/mysql start' ) or by simply running the mysqld_safe. MySQL can be shut down either with the init script, or with /path/to/mysqladmin shutdown -p ( and entering the password, if any ).

Have you ever had MySQL working on this computer? Maybe it's not fully installed. Check the manual on how to install. I only ever install from source, and I'm assuming you have used an RPM, so I can't really help you out here, but I'm sure this is covered in the manual. Maybe you just have to run the mysql_install_db script or something.

If you have MySQL installed properly but still can't access it with the mysql client, try adding the -h HOSTNAME switch ( and replace HOSTNAME with your ip address ). This will force the mysql client to connect to the server in the same way it would connect to a remote server ( as opposed to connecting via the mysql.sock file ).

Good luck.

--
Daniel Kasak
IT Developer
NUS Consulting Group
Level 5, 77 Pacific Highway
North Sydney, NSW, Australia 2060
T: (+61) 2 9922-7676 / F: (+61) 2 9922 7989
email: [EMAIL PROTECTED]
website: http://www.nusconsulting.com.au


-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]



Reply via email to