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!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Restore server settings from backup

Discussion in 'Data Protection' started by SSy, Feb 16, 2017.

Tags:
  1. SSy

    SSy Member

    Joined:
    May 10, 2016
    Messages:
    24
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Hi there - my hard drive has crashed and I am going to have to re-install WHM. I have all the accounts backed up but also have a number of settings customized in WHM. Is there a way to restore those settings or do I have to manually do all that? Such as cloudlinux settings, packages, all that sort of stuff?

    I have a full server backup including the settings.
     
  2. SSy

    SSy Member

    Joined:
    May 10, 2016
    Messages:
    24
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    I suppose more importantly, if I had version 56 on can I manually do system backups to version 62?
     
  3. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    38,127
    Likes Received:
    1,366
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
  4. SSy

    SSy Member

    Joined:
    May 10, 2016
    Messages:
    24
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Would it be better to install 56 then overwrite all the directories and files that were saved? Or do I have to do it pre-install first?

    And do I just run this:

    cd /home && curl -o latest -L https://securedownloads.cpanel.net/latest && sh latest

    after editing this file with the version I want:

    /etc/cpupdate.conf

    By adding this line:

    CPANEL=11.56.0.13
     
    #4 SSy, Feb 16, 2017
    Last edited by a moderator: Feb 16, 2017
  5. SSy

    SSy Member

    Joined:
    May 10, 2016
    Messages:
    24
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    So in essence, is the recovery process as follows?:

    1) Edit /etc/cpupdate.conf and add this line: CPANEL=11.56.0.13
    2) Run cd /home && curl -o latest -L https://securedownloads.cpanel.net/latest && sh latest
    3) Manually copy over all the backed up system files and directories and override the new ones, including mySQL.

    All my account data (home directory) is intact and saved. Can I just copy that over afterwards to the new home directory, or even better, remount it? Should I do that before or after installation?
     
  6. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    38,127
    Likes Received:
    1,366
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    You'd only want to manually restore individual configuration files that aren't already included in the account backup archives (e.g. /var/cpanel/cpanel.config, /etc/my.cnf, /etc/exim.conf.local, /etc/exim.conf.localopts). The individual backup archives will restore the account-specific data, so there's no need to copy over the home directories or databases (unless MySQL databases are not included in the backup archives).

    Thank you.
     
  7. SSy

    SSy Member

    Joined:
    May 10, 2016
    Messages:
    24
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Okay, so a couple of questions:

    1) Should I restore config files before or after installing WHM?
    2) Is the syntax I listed above the correct way to install version 56?
    3) Is there a list of the system files I should copy over? You listed 4 of them but how do I know which ones I should do? Can I not just override everything?
     
  8. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    38,127
    Likes Received:
    1,366
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    After.

    Yes, however note the /etc/cpupdate.conf file won't exist by default. You'll need to create it first.

    There's no list, as generally this feature is intended for use when restoring files on the same system (e.g. You make an Exim configuration change and want to revert it), as opposed to restoring files when a hard drive fails. Most of those files (e.g. /etc/passwd, /etc/localdomains, httpd.conf) are automatically populated when you restore the account. I recommend simply restoring the accounts and using the default configuration settings unless you are aware of any specific changes you made on the previous server.

    Thank you.
     
  9. SSy

    SSy Member

    Joined:
    May 10, 2016
    Messages:
    24
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Thank you very much. I will follow up if I have any other questions.
     
  10. SSy

    SSy Member

    Joined:
    May 10, 2016
    Messages:
    24
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    If you have any knowledge of Cloudlinux, is it better to first install WHM or first install Cloudlinux?
     
  11. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    38,127
    Likes Received:
    1,366
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Converting to CloudLinux after installing cPanel on a CentOS server is a simple process:

    CloudLinux Documentation

    However, you can also install CloudLinux from the start if you prefer:

    CloudLinux Documentation

    There's no difference between the converted servers and the servers with CloudLinux installed from the start.

    Thank you.
     
  12. SSy

    SSy Member

    Joined:
    May 10, 2016
    Messages:
    24
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Thank you very much.
     
Loading...

Share This Page