Am 2014-11-29 um 22:11 schrieb Marc MERLIN:
On Sat, Nov 29, 2014 at 09:34:01PM +0100, Jakob Schürz wrote:
Hi there!

I made a script to do backup with btrfs on a external HD.
You can see the function, how it works, and how it's to be used on
my site http://linux.xundeenergie.at/doku.php?id=mkbtrbackup
The site is in german. An english one will follow later.

Do you want some explanations?

Sure, how is it different from those 3?
https://btrfs.wiki.kernel.org/index.php/Incremental_Backup#Available_Backup_Tools

Wheter i haven't seen it, or this scripts can't do recursive backup...

If you have subvolumes in subvolumes (for example: /home, /home/user1, /home/user2 /var, /var/spool, /var/lib are extra subvolumes IN the normal filetree from linux), my script takes them all. It looks on the external storage, if there's an older snapshot (i call all subvolumes together in this case a snapshot!!) which is also on the local machine. If so, is makes a incremental backup. If not, a initial transfer is started. For each subvolume in the snapshot!

And my script changes the fstab-entry in the new snapshot.
The original has the option "subvol=@SUBVOL", where @SUBVOL is the name of the original system. It changes the @SUBVOLUME to the subvolume-id, so you can mount your snapshot easy.

One Point is missing... Modifying of grub to serve boot-menu-entries for older snapshots.

You get a systemd-unit, in the tarball, which makes a snapshot from your system, on successful boot, so you can switch back fast, if an update destroyed your system.

And it is for minimal-systems... no python, no perl, no java... only shell(bash) :-)

regards
jakob


--
http://xundeenergie.at
http://verkehrsloesungen.wordpress.com/
http://cogitationum.wordpress.com/

--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to