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.

Error, Link to database cannot be established

Discussion in 'Database Discussions' started by aun4some1, Mar 2, 2014.

  1. aun4some1

    aun4some1 Registered

    Mar 2, 2014
    Likes Received:
    Trophy Points:
    cPanel Access Level:
    Website Owner
    I am having an error when i restore my backup that i have on my local machine (Hard Drive).

    Actually recently i moved both of my domain name and hosting. I moved domain to godaddy and hosting rxpshost (a local reseller). I created the complete and partial back up of all before moving the website.
    After move, i restored partial backup from Backup Wizard. First, i restored Home Directory. 2nd i restored MySQL database and email filters and forwarders on 3rd.
    Home directory seems ok as well as webmail but SQL is throwing error in result i visit the website.

    The Error is "Link to database cannot be established: SQLSTATE[HY000] [1045] Access denied for user 'mugstra_prest29'@'localhost' (using password: YES)"

    I noticed that in cPanel home> MySQL Database, Database exist with name "mugstra_prest29" but there is no user exists in MySQL current user.

    So i think the error is with user that only database has restored but user has not been restored.
    Unfortunately i forgot the name of old user :( but i have the password of that user :) .

    I already tried some methods but found in forums but those did not worked for me :(.

    Is there anyway that could resolve this issue, i really need help on this as this project is really very important to me.
    I am really hoping a helpful help from cPanel experts.
  2. Infopro

    Infopro cPanel Sr. Product Evangelist
    Staff Member

    May 20, 2003
    Likes Received:
    Trophy Points:
    cPanel Access Level:
    Root Administrator
    Create a new user with a new password, and associate that user with that database. Then edit the config file for the site and add that new user and his password.

Share This Page