View Single Post
  #7  
Old 22nd April 2012, 16:16
lobius lobius is offline
Member
 
Join Date: Apr 2012
Posts: 41
Thanks: 1
Thanked 0 Times in 0 Posts
Default

Okay… Dumb question time:

Do I have to make those directories? Do I have to make them writable?

Would it be wiser to use chown root:root instead of chmod 777?

Quote:
Originally Posted by datahellas View Post
I needed a backup script for ISPConfig 3. I found this one by go0ogl3 but it was not exactly what I needed. I needed to backup the databases and only the clients/clientX/webX/ directories for each web site on the server. So I created a shell script for backup (not restore) that it is very simple but works excellent (at least on my server).

The script will take a daily backup and a weekly backup. The daily backup is being refreshed everyday while the weekly backup every Sunday. The weekly backup is the last daily backup taken (Saturday's backup).

Link to the script:
ISPConfig3 backup script


Rename it to ispc3backup.sh and chmod to 777 before you use it.
Open the file and set the variables in the very beginning (BACKUPDIR, CLIENTSDIR, DBUSER, DBPASS).
Install a crontab like the following to run it daily:

30 04 * * * /backup/ispc3backup.sh &> /dev/null

The script will put backups into these dirs:
BACKUPDIR/db/daily/
BACKUPDIR/db/weekly/
BACKUPDIR/webs/daily/
BACKUPDIR/webs/weekly/


I don't provide any support for this script. If you like it, use it.
Greetings from the Elxis CMS Team.
Reply With Quote