DSL Ideas and Suggestions :: Ultra-fast backup/restores



CBagger, Mikshaw et al

Here's another script extension, altered so compression levels can be set in the file /home/dsl/.backuprc

These get applied to gzip (and lzop if it is loaded).

Run it in a root shell:

Code Sample
time filetool.sh backup X hdb6


Docs say that lzop -1 probably wouldn't make much difference, and it didn't.  So I'm happy with default lzop (which is -3).

Setting the compression levels for busybox gzip doesn't make any difference to speed etc.  Gnu-utils are needed.

Unless gzip from gnu-utils is put into the base, there's no point in changing the comp level of gzip in the default filetool.sh.

----------------

lzop -3 ( ~5 secs on my tarball; level 3 is the default) still backs up around three times faster than gnu-utils gzip -1 (~15 secs) - as the hype says - with the lzopped tarball 9.3% bigger.

I think that putting the GNU gzip into the base ISO would be a good thing.  In addition to the whole speed issue, some users now get an "invalid magic" error from busybox gzip and no such error when using GNU gzip.

In the past, there was a similar problem with the "tar" command and the developers decided to replace busybox tar with GNU tar, so there is hope for gzip.

Quote
putting the GNU gzip into the base ISO would be a good thing

Agreed, for both reasons. It's not very big either, but I haven't checked to see if the libs are different (not on dsl now).

Meanwhile I've done a generalised version of that hack - now a re-write really - of filetool.sh.

It will do backups with gzip, lzop, bzip2 at different comp levels where possible, options can be set by the user, and I may get it to offer lzma, gpg and rzip choices as well.

Can do bzip2, lzop or gzip -9, or whatever. I was only interested in faster backups myself but ....

I'll post it in a new thread once I've tested some more (next week), assuming people are interested.

Here is a bugfix and a number of improvements to the fast backup scripts:

- Fixed bug that incorrectly gave "failed" message on successful restore of encrypted lzop archive.

- Only stores a device name in /opt/.backup_device if backup/restore using that device is successful.  Prevents trying to auto backup to a bad device on shutdown, with a consequent loss of data (also an issue in the normal backup scripts).

- New dsl-restore.sh scans for lzopped as well as gzipped archives - no need to point 'protect' or 'restore' at the device in the boot options (eg 'restore=hdb6').  But requires a remaster of your iso to overwrite the normal dsl-restore.sh for it to work this way.

Other changes are described at the top of the scripts.

md5sum is 8d7f239220fbb65dc3880e8785584bd7

How do i make a backup.tar.gz from an exsisting backup.tar.lzo?
Next Page...
original here.