Results 1 to 8 of 8

Thread: Backing up cpanel and clients

  1. #1
    Member
    Join Date
    Jun 2012
    Posts
    15
    cPanel/WHM Access Level

    Root Administrator

    Default Backing up cpanel and clients

    Hey! I just moved from Plesk to CPanel and need some help to get started with CPanel. I hope I can find a nice solution here!

    So I have a server running CentOS 6 with WHM 11.32.3 (build 19) where I host all my clients. If this server crashes I would like to have an identical backup of the http-files and MySQL on an offsite server. So if the server crashes I can just change the A-record of the domains and then the websites are back on.

    I started to read about the clustering functionality within CPanel, but as I understand this is only for DNS, it doesn't copy any files or mysql between servers? Right now I'm using an external nameserver (Anycast DNS) and would probably like to continue with that if you guys don't have another recommendation...

    The server is just running web (no mail).

    Thank you in advance

  2. #2
    cPanel Staff cPanelTristan's Avatar
    Join Date
    Oct 2010
    Location
    somewhere over the rainbow
    Posts
    7,611
    cPanel/WHM Access Level

    Root Administrator

    Default Re: Backing up cpanel and clients

    Hello,

    If you wish to have off server backups using the current implementation, we have FTP backups you can run to a remote machine. Those backups are packaged copies of the accounts, though, and it sounds like you want to clone the server rather than back it up. Is that what you are wanting to do, clone it?

    Otherwise, are you wanting instead to load balance it via clustering, which also differs from cloning or backing up a machine. Since all concepts differ in what they do and all three were mentioned, could you please indicate which it is precisely you are wanting? Right now, only backing it up is possible, but we do have various discussions that have already occurred on how to try to clone and how to try to cluster various services.

    Thanks!
    cPResources: Support Options | More Support Options | Forums Search | cPanel.net Site Search | Mailing Lists(Alt) | Docs
    -- Tristan, Technical Analyst III, Forums Specialist, cPanel Tech Support

    Submit a ticket | Check an existing ticket

  3. #3
    Registered User
    Join Date
    May 2012
    Posts
    3
    cPanel/WHM Access Level

    Website Owner

    Default Re: Backing up cpanel and clients

    add interactive guide to your site and it will explain you what to do automatically.
    check it at WalkMe for cPanel | WalkMe.
    i'm using it all the time for all the tasks...

    Cheers,
    Ron

  4. #4
    Member
    Join Date
    Jun 2012
    Posts
    15
    cPanel/WHM Access Level

    Root Administrator

    Default Re: Backing up cpanel and clients

    Quote Originally Posted by cPanelTristan View Post
    Hello,

    If you wish to have off server backups using the current implementation, we have FTP backups you can run to a remote machine. Those backups are packaged copies of the accounts, though, and it sounds like you want to clone the server rather than back it up. Is that what you are wanting to do, clone it?

    Otherwise, are you wanting instead to load balance it via clustering, which also differs from cloning or backing up a machine. Since all concepts differ in what they do and all three were mentioned, could you please indicate which it is precisely you are wanting? Right now, only backing it up is possible, but we do have various discussions that have already occurred on how to try to clone and how to try to cluster various services.

    Thanks!
    I want to clone the public_html files and MySQL databases, and maybe also the whole server if that's necessary. If the server goes down I want to be able to quickly change the A-records of the sites to the cloned server. In this way, as I see it, I have both backups and a mirror.

    Load balancing is not something I'm looking for, but I'm open for all kind of solutions if you have any ideas.

  5. #5
    Member
    Join Date
    Jun 2012
    Posts
    15
    cPanel/WHM Access Level

    Root Administrator

    Default Re: Backing up cpanel and clients

    Quote Originally Posted by cPanelTristan View Post
    Hello,

    If you wish to have off server backups using the current implementation, we have FTP backups you can run to a remote machine. Those backups are packaged copies of the accounts, though, and it sounds like you want to clone the server rather than back it up. Is that what you are wanting to do, clone it?

    Otherwise, are you wanting instead to load balance it via clustering, which also differs from cloning or backing up a machine. Since all concepts differ in what they do and all three were mentioned, could you please indicate which it is precisely you are wanting? Right now, only backing it up is possible, but we do have various discussions that have already occurred on how to try to clone and how to try to cluster various services.

    Thanks!

    Did you have any solution for me?

  6. #6
    cPanel Staff cPanelTristan's Avatar
    Join Date
    Oct 2010
    Location
    somewhere over the rainbow
    Posts
    7,611
    cPanel/WHM Access Level

    Root Administrator

    Default Re: Backing up cpanel and clients

    If you want to clone the server, the first step would be to create backups of all the accounts you already have using cPanel and then transfer and extract those accounts onto the new machine. If the new machine has cPanel, you could use WHM > Transfers area to copy all of those accounts.

    Once you've done that, the next step would be to rsync the data over. You could use the suggestions in this post to accomplish that task:

    http://forums.cpanel.net/f5/rsync-ba...tml#post671150

    Next, for the cPanel configuration files for WHM, EasyApache and so on, you'd want to copy these files:

    http://forums.cpanel.net/f5/process-...tml#post831162

    For these rsyncs, you'd want to then cron them to periodically run every so often. Otherwise, you would look into something like lsyncd for faster, non-cron based syncing:

    lsyncd - Lsyncd (Live Syncing Daemon) synchronizes local directories with a remote targets - Google Project Hosting

    For MySQL, I would suggest only using MyISAM for this method rather than InnoDB. You cannot live copy flat files when InnoDB is being used. You could end up corrupting MySQL data if you do that. If you do choose to use InnoDB tables, you'll need to mysqldump the databases to save them rather than relying on flat file syncing or transfers.

    Thanks!
    cPResources: Support Options | More Support Options | Forums Search | cPanel.net Site Search | Mailing Lists(Alt) | Docs
    -- Tristan, Technical Analyst III, Forums Specialist, cPanel Tech Support

    Submit a ticket | Check an existing ticket

  7. #7
    Member
    Join Date
    Jun 2012
    Posts
    15
    cPanel/WHM Access Level

    Root Administrator

    Default Re: Backing up cpanel and clients

    Quote Originally Posted by cPanelTristan View Post
    If you want to clone the server, the first step would be to create backups of all the accounts you already have using cPanel and then transfer and extract those accounts onto the new machine. If the new machine has cPanel, you could use WHM > Transfers area to copy all of those accounts.

    Once you've done that, the next step would be to rsync the data over. You could use the suggestions in this post to accomplish that task:

    http://forums.cpanel.net/f5/rsync-ba...tml#post671150

    Next, for the cPanel configuration files for WHM, EasyApache and so on, you'd want to copy these files:

    http://forums.cpanel.net/f5/process-...tml#post831162

    For these rsyncs, you'd want to then cron them to periodically run every so often. Otherwise, you would look into something like lsyncd for faster, non-cron based syncing:

    lsyncd - Lsyncd (Live Syncing Daemon) synchronizes local directories with a remote targets - Google Project Hosting

    For MySQL, I would suggest only using MyISAM for this method rather than InnoDB. You cannot live copy flat files when InnoDB is being used. You could end up corrupting MySQL data if you do that. If you do choose to use InnoDB tables, you'll need to mysqldump the databases to save them rather than relying on flat file syncing or transfers.

    Thanks!
    Thanks alot!

    When I create a new user on the live server, do I have to backup that account and restore it on the backup machine or is that also coming automatically with rsync?

    Has anyone tried Unison to sync files?

  8. #8
    cPanel Staff cPanelTristan's Avatar
    Join Date
    Oct 2010
    Location
    somewhere over the rainbow
    Posts
    7,611
    cPanel/WHM Access Level

    Root Administrator

    Default Re: Backing up cpanel and clients

    That should come automatically with rsync instead at that point.
    cPResources: Support Options | More Support Options | Forums Search | cPanel.net Site Search | Mailing Lists(Alt) | Docs
    -- Tristan, Technical Analyst III, Forums Specialist, cPanel Tech Support

    Submit a ticket | Check an existing ticket

Similar Threads

  1. Backing Cpanel freebsd based to Centos
    By fahmi in forum cPanel & WHM Discussions
    Replies: 10
    Last Post: 11-04-2011, 09:58 AM
  2. Replies: 6
    Last Post: 09-12-2011, 06:30 PM
  3. backing up a wrdpress site with Cpanel
    By dogznmogz in forum New User Questions
    Replies: 1
    Last Post: 04-06-2010, 11:55 PM
  4. Backing up cPanel settings/binaries to another server
    By divisionbyzero in forum cPanel & WHM Discussions
    Replies: 5
    Last Post: 08-18-2006, 05:33 AM
  5. Backing up lots of cpanel accounts
    By justahost in forum cPanel & WHM Discussions
    Replies: 0
    Last Post: 12-07-2003, 02:59 PM