The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

MySQL broke last night

Discussion in 'General Discussion' started by erinspice, Nov 29, 2007.

  1. erinspice

    erinspice Well-Known Member

    Joined:
    Feb 12, 2006
    Messages:
    99
    Likes Received:
    0
    Trophy Points:
    16
    I've had this server for 2-3 years, and all of a sudden this morning i can't connect to MySQL anymore. I'm still using 4.1.22. I thought about attempting an upgrade to fix this problem, but since I can't connect to MySQL to back up my databases, I would rather not.

    The error is a generic ERROR 2002 (HY000): Can't connect to local MySQL server through socket /var/lib/mysql/mysql.sock' (2). This is using the same username/password combo that worked just fine on this site yesterday. I've tried stopping and restarting MySQL. That went smoothly, but didn't fix the problem. I can't connect with root either.

    Any ideas?

    Code:
    root@foxtrot [~]# ls -l /var/lib/mysql/mysql.sock
    srwxrwxrwx  1 mysql mysql 0 Nov 29 09:33 /var/lib/mysql/mysql.sock=
    root@foxtrot [~]# 
     
  2. cPanelKenneth

    cPanelKenneth cPanel Development
    Staff Member

    Joined:
    Apr 7, 2006
    Messages:
    4,458
    Likes Received:
    22
    Trophy Points:
    38
    cPanel Access Level:
    Root Administrator
    Execute /scripts/restartsrv_mysql --check
     
  3. cPanelKenneth

    cPanelKenneth cPanel Development
    Staff Member

    Joined:
    Apr 7, 2006
    Messages:
    4,458
    Likes Received:
    22
    Trophy Points:
    38
    cPanel Access Level:
    Root Administrator
    OK, that sounds more serious. Is there any indication of problems with MySQL in the system logs, or in /var/cpanel/updatelogs?

    Are there any MySQL processes running?
     
  4. erinspice

    erinspice Well-Known Member

    Joined:
    Feb 12, 2006
    Messages:
    99
    Likes Received:
    0
    Trophy Points:
    16
    It just hangs, never printing anything out. Now I can't start MySQL at all. I restarted it a few times successfully this morning, but now I can't restart it with restartsrv_mysql or the init.d script.
     
  5. erinspice

    erinspice Well-Known Member

    Joined:
    Feb 12, 2006
    Messages:
    99
    Likes Received:
    0
    Trophy Points:
    16
    The problem was that I had run out of disk space. :rolleyes: Thanks for the help.
     
  6. cPanelKenneth

    cPanelKenneth cPanel Development
    Staff Member

    Joined:
    Apr 7, 2006
    Messages:
    4,458
    Likes Received:
    22
    Trophy Points:
    38
    cPanel Access Level:
    Root Administrator
    Heh, yeah, that would do it. Glad you were able to find it quickly.
     
Loading...

Share This Page