Hi guys, I am running ISPConfig 3 with apache2 and ubuntu 18.04 and i want to make a Backup of the ISPconfig itself. So when the data is lost on the server i want to make a clean new install of ISPConfig and then backup the config files of ISPConfig and then restore the backups of the websites. Are there scripts available or how are you doing your backups? thanks for your kind help
I use BackupPC to make backups of the files in the server. In addition, I install automysqlbackup on server so all databases are dumped to a file every night (and then BackupPC copies the dump files for safe keeping). You can in addition to the above make disk image backups. This is easy if ISPConfig is running on virtual host, then there is a button to do the disk image backup. If ISPConfig is running on a physical host, Clonezilla or similar can make disk image backup. https://clonezilla.org/ Also the ISPConfig upgrade instructions tell how to make backup of ISPConfig.
thanks a lot for your kind help. i backup the /var/www/ directory so i have all the user data right? as well i make a mysql dump of all databases Then i want to use rsync for copy the backup to the backup server with a cronjob. which directory should i backup to backup the ISPConfig? Does this work if i only copy the files from ISPConfig or is it better to make the ISPConfig upgrade backup? I run ubuntu 18.04 with apache2, which more files i should backup? config files of apache or something else? For example if the server is hacked i would install with ISPConfig standard install and then i want to backup my files. Which files would you recommend for backup? BackupPC i dont find a simple documentation it sounds a bit difficult to be honest thanks for helping me so much.
Users should not be able to write files elsewhere, so all files should be in /var/www/clients/* directory tree. In /var/www/ there are only symlinks. Like I wrote in #2: I do not understand what you are asking here: Config files are worth backing up, also several other files like logs in /var/log. If BackupPC is not to your liking, use something else: https://help.ubuntu.com/lts/serverguide/backups.html https://help.ubuntu.com/community/BackupYourSystem
Mail lives under /var/vmail/ so don't forget that if you host email. /usr/local/ispconfig/ and maybe the web server config under /etc/apache2/ (though you can regenerate that when reinstalling ispconfig) and ssl certificates (letsencrypt certs would be under /etc/letsencrypt). You'll probably want a copy of everything under /etc for reference (eg. passwd/shadow/group would be pretty handy). All of them, or at least any you need to be able to recover at a later time. See https://www.howtoforge.com/community/threads/ispconfig-3-with-backup-system.34332/#post-374134
Was the backup of ISPConfig right along with the MySQL databases? I want to perform the same type of backup.
personally, I run data and configuration backups separately. I use automysqlbackup to backup client databases every night. I backup /var/www and /var/vmail every night. that handles all the client's own data. for the configuration, I run a script to mysqldump the dbispconfig database and tar.gz the folders /etc, /opt, /usr/local/ispconfig, and any other folders that may be used, eg for attempting pci compliance, I've re-installed phpmyadmin so instead of /etc/phpmyadmin, most of the files are now in /usr/share/phpmyadmin, so that gets included as well. that gets run nightly on every ispconfig member server.