2002 Can't connect to local MySQL server through socket '/tmp/mysql.sock'(46)

2002 Can't connect to local MySQL server through socket '/tmp/mysql.sock'(46)

Post by David Powe » Sat, 11 Jun 2005 06:44:03



It sounds as though you've made a mess of things. Presumably if you're
using WinMySQLAdmin, you're on Windows, although I've only ever come
across the socket problem on Mac OS X or Linux.

One thing you can try is this (assuming you're on Windows):

Open a Windows Command Prompt window
Type the following commands:

cd c:\mysql\bin
mysqladmin -p -u root -h 127.0.0.1 shutdown

Enter your MySQL root password when prompted.

That should close down MySQL. You can then try restarting it.

If that doesn't work, you should completely uninstall MySQL and start
all over again.

--
David Powers
Author, "Foundation PHP 5 for Flash" (friends of ED)
Co-author "PHP Web Development with DW MX 2004" (Apress)
http://www.yqcomputer.com/