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!

How to manually initiate nightly backup from the command line?

Discussion in 'General Discussion' started by cPanelBilly, Jan 9, 2008.

  1. cPanelBilly

    cPanelBilly Guest

    There is no way easy to do this, best would probably be to just rsync the files (or ftp them if you prefer)
  2. livewebcs

    livewebcs Member

    Jun 11, 2004
    Likes Received:
    Trophy Points:
    How to manually initiate nightly backup from the command line?

    Is there a way from the command line to run the nightly backup of CPANEL and specify an FTP source?

    We backup nightly to hard disk but I would like to also backup to FTP to a second source every once and a while.

    Thus I am looking for a solution where I can run a second backup run (to FTP) every once and a while.
  3. cPanelKenneth

    cPanelKenneth cPanel Development
    Staff Member

    Apr 7, 2006
    Likes Received:
    Trophy Points:
    cPanel Access Level:
    Root Administrator
    You could have a secondary cpbackup.conf file with the FTP details in it. ONce you have that, create a shell script that:

    1. Renames the real cpbackup conf file
    2. Puts the FTP cpbackup conf file in place
    3. Executes /scritps/cpbackup --force (without --force the backup might fail with 'Backup is already up to date').
    4. Once the backups complete (will have to monitor processes for this), undo steps 2 and 1

    You could then execute the shell script manually.
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice