I am using Lucky Backup with oS v13.1x64 KDE.
I finally have a usb HD large enough to backup more than only my /home directory
While backing up the entire system (full backup) I discovered the file kcore and had to abort due to it’s huge size and plan to add that to my excludes list as apparently I don’t need to backup that file because it is a virtual file.
In looking for more info on what to exclude I find recommendations to exclude /sys, /dev, & /proc but I don’t understand why those can be excluded.
My question is that if I need to restore, say, due to a failed HD, if I exclude all those directories I don’t see how I can get a working system restored.
So if I need to restore should I do a fresh install and then restore things like /home, /etc, and who knows what else?
I would like to know which directories (and/or files) I can safely not backup, or is kcore the only one I need to exclude. I know I don’t need cache, temp, and that sort of thing.
All those are virtual file systems For example /proc is a window in the kernel. In Linux all things are files. /dev is a list of devices the system sees. /sys is a system related folder. These folders are all virtual and are created at run time and are not data on the disk.
Note also that you should have a Linux file system on the backup device to preserve the ownership permission on the file. Lucky uses rsync so you will lose permission if copying to a MS file system. Note there are other backup methods that that use tar and compressed tar in which case the permissions are saved in the tar and are thus safe on a MS formatted drive
> In looking for more info on what to exclude I find recommendations to
> exclude /sys, /dev, & /proc but I don’t understand why those can be
> excluded.
Because they don’t really exist, they are virtual.
Also, some chrooted services duplicate some of those directories you
don’t need to backup, somewhere in /var.
I do the backup of the system parts as a partition image, done while the
system is not running, ie, while running another system. Then all those
virtual directories are empty, and in any case, it doesn’t matter when
you do an image, the size is the full size of the partition. I do it
that way because restore is faster. Other people only backup /etc, they
consider that installing the system again is fast enough.
For home I use rsync.
–
Cheers / Saludos,
Carlos E. R.
(from 12.3 x86_64 “Dartmouth” at Telcontar)
Apart from /home, I only back up any /etc files which I have modified, a couple of non-standard fonts and mysql files because the rest is easy to reinstall (and probably quicker to reinstall than to restore from a backup).
On 2013-11-27 22:06, gogalthorp wrote:
>
> Note also that you should have a Linux file system on the backup device
> to preserve the ownership permission on the file. Lucky uses rsync so
> you will lose permission if copying to a MS file system. Note there are
> other backup methods that that use tar and compressed tar in which case
> the permissions are saved in the tar and are thus safe on a MS formatted
> drive
A note, though: I do not trust compressed tars as reliable backups. Just
a one byte error, and the entire archive is lost, decompression error.
However, I can not propose an alternative I consider safe and good
enough. It should be a method that compresses file by file, then put
them in a single archive. Or it could be a method that includes
autorepair blocks. The commercial RAR application does so, but besides
being commercial I think it does not backup/restore all the unix type
attributes.
I did see a backup script that was safe about a decade ago. It used cpio
with compression by single files. But it disappeared from distribution.
–
Cheers / Saludos,
Carlos E. R.
(from 12.3 x86_64 “Dartmouth” at Telcontar)