Web Hosting Forum | Lunarpages


*
Welcome, Guest. Please login or register.
Did you miss your activation email?



Login with username, password and session length
September 02, 2010, 07:22:02 AM

Pages: [1]   Go Down
  Print  
Author Topic: MySQL Issues  (Read 7819 times)
Jason2
Galactic Royalty
*****
Offline Offline

Posts: 203


WWW
« on: March 06, 2008, 11:18:33 AM »

Can't connect to local MySQL server through socket

This means:

1. MySQL crashed, it's not running or it can't find the socket. You need to contact Lunarpages support about this.

2. If your running a vBulletin board, then it means the info in your config.php file is wrong (in which case your forums wouldn't work at all).

Here is more info on this error:

MySQL 5.1:
http://dev.mysql.com/doc/refman/5.1/en/can-not-connect-to-server.html

MySQL 5.0:
http://dev.mysql.com/doc/refman/5.0/en/can-not-connect-to-server.html

MySQL 3.23, 4.0, 4.1:
http://dev.mysql.com/doc/refman/4.1/en/can-not-connect-to-server.html

In Windows:
http://dev.mysql.com/doc/refman/5.1/en/can-not-connect-to-server-on-windows.html
http://dev.mysql.com/doc/refman/5.0/en/can-not-connect-to-server-on-windows.html

Lost connection to MySQL server during query

Below are some of the most common reasons to receiving this error:

1. Because you have issued a ``close'' on your MySQL connection and then tried to run a query on the closed connection. You can check that the MySQL hasn't died by executing mysqladmin version and examining the uptime.

2. Are you trying to run a query against your database that is either incorrect or too large? If mysqld gets a packet that is too large or out of order, it assumes that something has gone wrong with the client and closes the connection.

3. Or your host has restarted mySQL. If this is the case, just simply contact the wonderful LunarPages support!

Useful links:
http://www.mysql.com/doc/C/o/Common_errors.html
http://www.mysql.com/doc/G/o/Gone_away.html
http://www.mysql.com/doc/S/e/Server_parameters.html
http://www.mysql.com/doc/O/p/Option_files.html
http://www.mysql.com/doc/S/H/SHOW_VARIABLES.html
http://dev.mysql.com/doc/

I'll add more when I get around to doing so.

Regards Jason Smile
« Last Edit: March 06, 2008, 12:19:58 PM by Jason2 » Logged

"Anyone who has never made a mistake has never tried anything new." -- Albert Einstein
Mitch
Berserker Poster
*****
Offline Offline

Posts: 12840


WWW
« Reply #1 on: March 06, 2008, 11:39:18 AM »

Stickied this, thanks again Jason!
Logged

New to Web Site Hosting? Check Out the Lunarpages Blog Hosting Guide!


Follow us @lunarpages on Twitter!
Important Threads: Read This Before Posting! | Lunarforums Rules! | Mitch's Link of the Day!
Also, be sure to check out and subscribe to the Lunartics Blog and the Lunarpages Newsletter !

Need Web Hosting Help? Check out the Lunarpages Web Hosting Wiki. It has tons of tips, tutorials and resources!
Jason2
Galactic Royalty
*****
Offline Offline

Posts: 203


WWW
« Reply #2 on: March 06, 2008, 11:43:55 AM »

Not a problem at all Mitch.

Thanks!

Regards Jason Smile
Logged

"Anyone who has never made a mistake has never tried anything new." -- Albert Einstein
vks87
Intergalactic Cowboy
*****
Offline Offline

Posts: 63


« Reply #3 on: April 01, 2009, 11:42:16 PM »

Thanks for the links..
and ofcourse for the article..
Logged
clever_clown
Galactic Royalty
*****
Offline Offline

Posts: 252



« Reply #4 on: March 21, 2010, 05:54:12 AM »

I'm trying to execute this command: mysqldump --user=root --password=mypass --all-databases | gzip > db.gz

but it gives an error:
mysqldump: Got error: 2002: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) when trying to connect

With reference to my search, the answer was, this problem is from the hosting company, kindly check the post of LincolnForums through this link out:
http://www.vbulletin.org/forum/showthread.php?t=106935

Cheers,
Logged
SarahPerez10
PLAVEB Corporation
Trekkie
**
Offline Offline

Posts: 19


WWW
« Reply #5 on: August 20, 2010, 02:57:16 AM »

Nice post, Thanks for sharing your knowledge with us.   Smiling
Logged

Pages: [1]   Go Up
  Print  
 
Jump to: