Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

MySQL + phpMyAdmin

Discussion in 'Database Discussion' started by xbuzz, Jan 5, 2006.

  1. xbuzz

    xbuzz Member

    Joined:
    Nov 26, 2005
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    151
    MySQL and phpMyAdmin are not functioning properally. When I select "phpMyAdmin" from "WHM" I recieve the following error message from phpMyAdmin

    Wrong username/password. Access denied.

    I reset the password and it appears to be correct even in /root/.my.cnf

    When I log into the server via shell as root and type "mysql -u root" I get the following error message.

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

    Any help would greatly be appreciated!
     
  2. linux-image

    linux-image Well-Known Member

    Joined:
    Jun 8, 2004
    Messages:
    1,191
    Likes Received:
    1
    Trophy Points:
    168
    Location:
    India
    cPanel Access Level:
    Root Administrator
    on shell as root type:

    /etc/rc.d/init.d/mysql restart

    then check to see if there are any errors specified.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. madaboutlinux

    madaboutlinux Well-Known Member

    Joined:
    Jan 24, 2005
    Messages:
    1,051
    Likes Received:
    2
    Trophy Points:
    168
    Location:
    Earth
    Set the permissions of /tmp directory to 1777 and also check whether the mysql.sock is present in the /tmp, if not, do the following :-
    chmod 1777 /tmp
    ln -s /var/lib/mysql/mysql.sock /tmp
    service mysql restart

    If the above doesn't fix the issue, execute the below script :-
    /scripts/mysqlup --force
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. xbuzz

    xbuzz Member

    Joined:
    Nov 26, 2005
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    151
    i just ran that script and the problem still exists. additionally i ran "updatedb" and then typed "locate mysql.sock" nothing was found. any ideas???

    thanks for the reply
     
  5. madaboutlinux

    madaboutlinux Well-Known Member

    Joined:
    Jan 24, 2005
    Messages:
    1,051
    Likes Received:
    2
    Trophy Points:
    168
    Location:
    Earth
    Try adding the below lines in /etc/my.cnf
    [mysqld]
    datadir=/var/lib/mysql
    socket=/tmp/mysql.sock
    [client]
    socket=/tmp/mysql.sock

    and restart Mysql as given by :-
    /etc/rc.d/init.d/mysql restart

    Else paste the output of the below command :-
    /var/lib/mysql/bin/mysqld_safe &
    or
    /usr/bin/mysqld_safe &
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  6. madaboutlinux

    madaboutlinux Well-Known Member

    Joined:
    Jan 24, 2005
    Messages:
    1,051
    Likes Received:
    2
    Trophy Points:
    168
    Location:
    Earth
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice