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.

Cpanel Backup Question

Discussion in 'General Discussion' started by hbhb, Jul 5, 2007.

  1. hbhb

    hbhb Well-Known Member

    Joined:
    Dec 1, 2006
    Messages:
    67
    Likes Received:
    0
    Trophy Points:
    6
    I'm new to CPanel backup, so I wish to check with any of you guys with experience if I am doing the right thing:

    My current backup configuration were as follows:

    Interval : Daily
    Retention: Daily, Weekly, Monthly
    Days to run backup: Sunday-Saturday (Daily)
    Remount/UnMount : Disable
    Bail out Drive: Disable
    Incremental Backup: Disable
    Backup Accounts: Enable
    Backup Config Files: Enable
    SQL Databases: Per Accounts only
    Backup Raw Access Logs: Disable
    Backup Type: Standard
    Use Pasive Mode FTP: Disable
    Backup Destination: /backup

    This shall means that it will create /backup/cpbackup/daily & /weekly & /monthly in .tar.gz compressed format.

    I just got a remote backup server (Another IP Address in the same datacenter rack)

    What I want to do is to change my ways of backup into something like this:

    - I want to enable daily uncompressed incremental backup for Daily/Weekly only
    - I want it to Mount /backup when backup starts at 12 midnight and unmount /backup when process finishes
    - Next, I also want the backup to do Compressed backup on every Sunday & Wednesday into my remote FTP backup server

    How can I do that? Please guide me with configuration and crontab settings. I believe this require manual backend scripts which I don't know how to write or where to begin.
     
  2. jayh38

    jayh38 Well-Known Member

    Joined:
    Mar 3, 2006
    Messages:
    1,215
    Likes Received:
    0
    Trophy Points:
    36
    The easiest thing that comes to mind is creating two backup configurations and rename them at the appropriate times via cronjob.

    copy the original /etc/cpbackup.conf and rename that to cpbackup.conf.weekday
    Then create your weekend backup configuration and save it as cpbackup.conf.weekend

    Then a cronjob to change the names at the appropriate times.

    0 12 * * 5 cp -f /etc/cpbackup.conf.weekend /etc/cpbackup.conf ;
    0 12 * * 0 cp -f /etc/cpbackup.conf.weekday /etc/cpbackup.conf;

    At noon Friday (or whenever you want) the weekend conf will be copied as cpbackup.conf and Sundays at noon, your weekday will be in place instead.

    I am not truly sure if this will be overwritten by the system but someone will comment if this is not a good solution.
     
  3. hbhb

    hbhb Well-Known Member

    Joined:
    Dec 1, 2006
    Messages:
    67
    Likes Received:
    0
    Trophy Points:
    6
    Thanks jayh38 for your idea but i sense something wrong we had to rename the file but does not execute the cpbackup command

    Anyone else can guide me?
     
  4. jayh38

    jayh38 Well-Known Member

    Joined:
    Mar 3, 2006
    Messages:
    1,215
    Likes Received:
    0
    Trophy Points:
    36
    No, this will not execute the backup process, just merely setting the appropriate configuration you needed. If backups are enabled, which you show it is, then you already have a cronjob for cpbackup installed.

    If you want to change the backup process launch time then you will need to modify the entry for /scripts/cpbackup in your crontab to the desired time to launch.
     
  5. Secmas

    Secmas Well-Known Member

    Joined:
    Feb 18, 2005
    Messages:
    321
    Likes Received:
    0
    Trophy Points:
    16
    What option is less time (or load) consuming in the server, an incremental backup or a compression backup? Which one is better?

    Thanks for your comments.
     
  6. Fernis

    Fernis Well-Known Member

    Joined:
    Oct 28, 2006
    Messages:
    192
    Likes Received:
    1
    Trophy Points:
    18

    The incremental backup will creat much less load on the server since it isn't doing all of the accounts and gzip'ing them as compared to compression backup. However, the compression backup will occupy less space if you are concerned about that.
     
Loading...

Share This Page