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 error [moved]

Discussion in 'Database Discussions' started by ras`, May 29, 2006.

  1. ras`

    ras` Member

    Joined:
    Apr 25, 2006
    Messages:
    18
    Likes Received:
    0
    Trophy Points:
    1
    Hi,

    I am encountering error messages as I visit one of our site:

    Warning: mysql_connect(): Access denied for user: 'onlinecd_db2@xxx.xxx.xxx' (Using password: YES) in /home/internet/public_html/directory/class/db.php on line 28
    Error connecting to the serverAccess denied for user: 'onlinecd_db2@xxx.xxx.xxx' (Using password: YES)

    anyone encounter the same and tell me how to resolve this thing.
    glad to hear from anybody.

    ras
     
  2. tweakservers

    tweakservers Well-Known Member

    Joined:
    Mar 30, 2006
    Messages:
    379
    Likes Received:
    0
    Trophy Points:
    16
    are you connecting using ip address or using localhost? If IP address, does it allowed for the database in Cpanel allowed host?
     
  3. madaboutlinux

    madaboutlinux Well-Known Member

    Joined:
    Jan 24, 2005
    Messages:
    1,052
    Likes Received:
    2
    Trophy Points:
    38
    Location:
    Earth
    Try following the below steps.

    1. Login to cPanel for that domain.
    2. Goto 'Databases' and delete the user assigned to that particular database.
    3. Add the user and assign to the database again with full privilages.
    4. Edit the db.php file and replace the old database username/password with the new one you have just created.

    Also check whether your are using the servername as IP addr or localhost. Change it to 'localhost'

    Hope this will help you.
     
  4. kemis

    kemis Well-Known Member

    Joined:
    Feb 17, 2005
    Messages:
    104
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Georgetown, TX
    Yeah, going to WHM --> Change a User or Database Password and resetting my mysql root password back to my usual fixed the problem for me. Many others are having this same issue. Happened to me after an auto-upgrade last night to 4.1.19. :-(

    All is well again, I believe.

    -- Matt
     
  5. ras`

    ras` Member

    Joined:
    Apr 25, 2006
    Messages:
    18
    Likes Received:
    0
    Trophy Points:
    1
    Thanks guys for all the information,

    After deleting and replacing it, solves the problem.
     
Loading...

Share This Page