How to make an easy full system backup?
some time a go i made a dd image of my fedora 8 linode partition and downloaded it to my desktop pc. besides that the image was huge it didnt contain partition data and i was unable to mount it. because i only have ntfs partitions on my desktop i couldn repair it with knoppix…
so now i think of just copying important dirs onto my desktop on a regular basis using scp.
which directories are not senseful to backup, because they dont contain any user-application related settings or directories (/mnt, /dev) ?
my goal is to have a backup that i can restore after a new install of fedora and everything is up and running again. after my last failure, when i accidentaly deleted /bin i could recover by copying the bin dir from another fedora partition..
thx!
7 Replies
/etc
/home
/usr/local
I've got a nightly cron job that dumps and gzips MySQL databases into a directory under /home, so I get those as well, and also generates a list of packages installed via the package manager so I've always got an up-to-date list along with my backup.
If I ever need to restore a system, I can start with the base OS, add the packages from the list, and then copy the data and configurations over, and I'll back up and running.
Another option is outlined in this
Hope that helps…
@kwilson:
I typically back up three directories every night, via rsync:
/etc
/home
/usr/local
I've got a nightly cron job that dumps and gzips MySQL databases into a directory under /home, so I get those as well, and also generates a list of packages installed via the package manager so I've always got an up-to-date list along with my backup.
If I ever need to restore a system, I can start with the base OS, add the packages from the list, and then copy the data and configurations over, and I'll back up and running.
Hi kwilson. is your way of taking the backup
also keeping your modifications ?
I mean apache installed modules, mysql configurations and php as well?
if your going compiling your own packages from source or elsewhere, then you might need to alter your backup stragegy. Backups typically arent a "1 size fits all" system. You need to tailor it to your needs.
I personally back up
/etc
/var/log
/root
/var/lib/mysql
/home/nf
/home/hosting
/var/cache/mylvmbackup/backup
Here's my script, in case it's of any use.