MySQL Forums
Forum List  »  General

MySQL startup - ERROR 2002 (HY000)
Posted by: Hariharan Sridharan
Date: June 17, 2010 12:15PM

I am on Ubuntu 10.04 Lucid Lynx, MySQL Ver 14.14 Distrib 5.1.41. I had configured MySQL to run with MediaWiki and everything was working fine until I tweaked the Ubuntu proxy settings. My hostname is "sql-admin-desktop"

Settings before installing MYSQL:
On Ubuntu, there was a system-wide network proxy set with ignored hosts:

I installed MySQL, Mediawiki and was able to bring up the wiki. However, I could only use "http://localhost/mediawiki"; to access my wiki and not "http://sql-admin-desktop/mediawiki"; or "http://sql-admin-desktop";. After a little looking around, I saw that I had to add "sql-admin-desktop" to my Ignore-proxy list.

I updated system-wide network proxy on Ubuntu by adding to the ignored hosts. Hence my ignore-list now reads:

Then clicked on "Apply system-wide".

After this, I was able to bring up "http://sql-admin-desktop"; in the local system and within the intranet. However, when I tried to bring up MediaWiki on "http://sql-admin-desktop/mediawiki";, the browser said "Can't contact the database server: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) (localhost)".

On a terminal, I tried "mysql -u sql_admin -p", but get the error "ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)"

I am unable to find the .sock file anywhere on the system. After reading the MySQL docs, I think MySQL was connecting using TCP/IP earlier and not an external sock file.

Could you tell me how I could fix the proxy on MySQL so that it connects like before? I'd be glad to provide any additional details necessary.

Thank you!

Options: ReplyQuote

Written By
MySQL startup - ERROR 2002 (HY000)
June 17, 2010 12:15PM

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.