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.

SOLVED rename database cpanel still shows old name

Discussion in 'Database Discussions' started by asmithjr, Jul 24, 2017.

  1. asmithjr

    asmithjr Well-Known Member

    Joined:
    Jun 13, 2003
    Messages:
    498
    Likes Received:
    4
    Trophy Points:
    168
    I took the chance to try the rename database under the Operations. It worked. I was able to modify my websites config files and all will read and write from the newly named database.
    My problem comes when I access cPanel for the account the DB is under. I still see the old DB. I did a Check Database and it returns Check complete but still shows the old db name.
    I did restart MySQL and that too did not help solve the problem.
    What should I do to correct this? I'm not finding anything in the forums.
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    37,064
    Likes Received:
    1,287
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    Could you confirm if you renamed the database through phpMyAdmin? If so, this is unsupported and can result in issues with cPanel detecting the database name. The supported method of renaming a database is under the "Actions" tab under the MySQL Databases option in cPanel. As a workaround, try using "WHM Home » SQL Services » Database Map Tool" to map the new database name to the cPanel account.

    Thank you.
     
  3. asmithjr

    asmithjr Well-Known Member

    Joined:
    Jun 13, 2003
    Messages:
    498
    Likes Received:
    4
    Trophy Points:
    168
    In the users's phpmyadmin the DB does not appear. The old db name appears in the MySQL Databases for the user.
    In the root phpmyadmin the DB changed as expected and as I stated it works from the website forms.
     
  4. asmithjr

    asmithjr Well-Known Member

    Joined:
    Jun 13, 2003
    Messages:
    498
    Likes Received:
    4
    Trophy Points:
    168
    I cannot find the option for "The supported method of renaming a database is under the "Actions" tab under the MySQL Databases option in cPanel"
    I was able to use the Database Map Tool and now the DB shows up in the cPanel account.

    Strange if it is not supported to rename a DB the way I did it that it is even an option. I using 64.0.33 build.
     
  5. 24x7server

    24x7server Well-Known Member

    Joined:
    Apr 17, 2013
    Messages:
    1,399
    Likes Received:
    52
    Trophy Points:
    28
    Location:
    India
    cPanel Access Level:
    Root Administrator
    Hi,

    You have done it in different way. You have done through the cPanel interface itself, but you did it through PHPmyadmin, which has no control over the DB created through the cPanel interface. You may have broken the connectivity, so it will not display. Please note manual action do not reflect and same is the case in your scenario.

    Now, there are 2 ways for you to do this;
    1) Go through the cPanel architecture of this account and rename the DB manually to the new one that you changed..
    OR
    2) Take the backup of the current database manually properly, drop it first from the cPanel and then from phpmyadmin, after you remove the database completely from the server, create new one and restore the backup you took over the new database...
     
  6. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    37,064
    Likes Received:
    1,287
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    In "cPanel >> MySQL Databases", under "Current Databases", you should see a "Rename" link under the "Actions" column. It's documented under the "Rename A Database" section at:

    MySQL Databases - Documentation - cPanel Documentation

    Renaming a database through the MySQL command line or through phpMyAdmin is not supported.

    Thank you.
     
  7. asmithjr

    asmithjr Well-Known Member

    Joined:
    Jun 13, 2003
    Messages:
    498
    Likes Received:
    4
    Trophy Points:
    168
    Michael, I apologize about the Actions tab. I was looking for a tab on the page. I see where you are saying this. I did take care of this and all is well.
    Please marked this solved.
     
    cPanelMichael likes this.
Loading...

Share This Page