Re: root volume backup and devices
Denis Corbin <[email protected]> Sat, 12 Jul 2008 19:09:47 +0200
| Newsgroups | gmane.comp.sysutils.backup.dar.general |
|---|---|
| Message-ID | <[email protected]> |
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 T o n g a wrote : > Hi, Hi, > > What's the best practice dealing with devices when backing up the root > volume? Well, my own practice is to backup everything unless it is established to be useless (temporary or live system related for example): Thus I usually remove /tmp /var/tmp and the like, as well as /proc and /dev/pts under Linux and as well as /mnt (which hold the mounting points of removable media on my system). so far with dar this makes the following command-line (yes, I am using dar too ;-) ): dar -R / -c <somewhere> -P <somewhere> -P tmp -P var/tmp -P proc -P dev/pts -P mnt I also remove the many caching directory like this those created by seamonkey: - -P "home/*/.mozilla/*/Cache" For squid I backup the caching at full backup only to avoid having to manually rebuild the cache directory structure. Last I also find useful the -D option to not have to manually recreate all theses ignored directories. Of course you would also add compression and maybe encryption at your will. > > I used to use the following switches to backup my root volume: > > -P dev -P proc -P sys --no-mount-points > > I.e., I thought udev would populate /dev on boot up so I didn't back it > up. However, I got > > Warning: unable to open initial console > > from the restored system and the boot froze. > > Having gone through all the possible reasons in http://kerneltrap.org/node/2205 > did I realize that my /dev directory should be backed up & populated. > In fact, what's really important are the null, zero, console and tty[0-9] > devices. > > So if there is no good way dealing with devices, can I use '-P dev' to > exclude them all at first then include back those important devices? > If yes, how? I do not exclude /dev because I still use a static list of devices (not using udev). Now, if your are not just with your virtual memory when doing backup (especially differential backup) with dar, it does not hurt to backup even devices generated by udev. To me each thing your remove from a backup is a risk you take for it avoids your restored system to boot. For this reason I prefer to include everything except a well defined list of items, and for each having evaluated the risk I take not to include them (seen the way each is used). It is also probably a good thing to restore your backup on another computer (or virtual machine for example) to see if you will be able to recover your system from backup, before you really need to rely on your backup for that. But I guess that you too find this to be obvious. :-) > > Thanks > You're welcome, Regards, Denis. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFIeOVbpC5CI8gYGlIRAqzSAKCQnB0Pp0E1rvonNBMFhgQ33AkkZQCfYs7q 974GOZAUnNtvV8+Oz8HQRdg= =IgZJ -----END PGP SIGNATURE----- ------------------------------------------------------------------------- Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW! Studies have shown that voting for your favorite open source project, along with a healthy diet, reduces your potential for chronic lameness and boredom. Vote Now at http://www.sourceforge.net/community/cca08