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.

database backup

Discussion in 'General Discussion' started by geneticfreak, Feb 25, 2005.

  1. geneticfreak

    geneticfreak Member

    Joined:
    Dec 30, 2003
    Messages:
    13
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Reading, PA
    This is a real novice question, but will restoring a home directory backup also restore the SQL databases tied to a site or will they need to be done separately?
     
  2. JP-HOST

    JP-HOST Well-Known Member

    Joined:
    Sep 23, 2004
    Messages:
    59
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Roscoe, IL, USA
    No a home directory backup will not restore the databases, they must be done seperately. If you can restore a full backup, that has the MySQL databases in it.
     
  3. jhobbs

    jhobbs Member

    Joined:
    Feb 3, 2003
    Messages:
    24
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Sturgis, Michigan
    I have a cPanel "Full Backup" from just before a MySQL database error.

    I have no separate MySQL database backup.

    - If I do a cPanel "Restore a Home Backup", will it recover the MySQL databases?

    - Is there a way to restore the backup to a test domain, not the original domain?

    - Is there a way to restore only the MySQL database, not the other files?

    - The file "backup-4.19.2005_15-33-06_userid.tar.gz" exists in the \home\userid folder. Can I restore directly from it, or must I upload it from my home download?
     
    #3 jhobbs, Apr 24, 2005
    Last edited: Apr 24, 2005
  4. chirpy

    chirpy Well-Known Member

    Joined:
    Jun 15, 2002
    Messages:
    13,475
    Likes Received:
    20
    Trophy Points:
    38
    Location:
    Go on, have a guess
    All you should need to do is to copy the accounts backup from /backup/cpbackup/daily/account.tar.gz (or whereever you have configured your server backups to point to) to a temporary location and then run:

    tar -xzf account.tar.gz

    on the copied file. You should find a SQL file in the subdirectory account/mysql.sql which you can then import back into MySQL.
     
  5. jhobbs

    jhobbs Member

    Joined:
    Feb 3, 2003
    Messages:
    24
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Sturgis, Michigan
    Problem is, my backup was from cPanel's user account, not from WHM's backup. I expanded the backup using file manager, and there are no appropriate .SQL files. Is there a way to recover SQL data from a cPanel "Full Backup"?
     
Loading...

Share This Page