Hey,
i found a solution which works at least for
me pretty well. I’m using two sd cards. One is for my running system and the another one is for my backup.
Installation1) Sd-Card-B (backup system): Create 2 Partitions (boot and root) on it and install arch linux as described here
http://archlinuxarm.org/platforms/armv7/broadcom/raspberry-pi-2#qt-platform_tabs-ui-tabs22) Sd-Card-A (my running system): Create 2 Partitions (boot and root) on it as described here (do not install arch on it)
http://archlinuxarm.org/platforms/armv7/broadcom/raspberry-pi-2#qt-platform_tabs-ui-tabs23) Boot my backup Sd-Card-B and mount the boot partition from running system Sd-Card-A to /mnt/boot. Using rsync to sync this partition.
$this->bbcode_second_pass_code('', 'mount /dev/sda1 /mnt/boot')
$this->bbcode_second_pass_code('', 'rsync -aAXv --delete /boot /mnt/boot')
$this->bbcode_second_pass_code('', 'umount /mnt/boot')
4) Mount the root partition from Card-A to /mnt/root. Using rsync to sync this partition.
$this->bbcode_second_pass_code('', 'mount /dev/sda2 /mnt/root')
$this->bbcode_second_pass_code('', 'rsync -aAXv --exclude={"/dev/*","/proc/*","/sys/*","/tmp/*","/run/*","/mnt/*","/media/*","/lost+found","/boot"} --delete')
$this->bbcode_second_pass_code('', 'umount /mnt/root')
5) shutdown my backup system and start my running system Sd-Card-A
BackupI do it like the installation vice/versa
1) Boot my running system Sd-Card-A and mount the boot partition from my Backup Sd-Card-B to /mnt/boot. Using rsync to sync this partition.
$this->bbcode_second_pass_code('', 'mount /dev/sda1 /mnt/boot')
$this->bbcode_second_pass_code('', 'rsync -aAXv --delete /boot /mnt/boot')
$this->bbcode_second_pass_code('', 'umount /mnt/boot')
2) Mount the root partition from my backup Sd-Card-B to /mnt/root. Using rsync to sync this partition.
$this->bbcode_second_pass_code('', 'mount /dev/sda2 /mnt/root')
$this->bbcode_second_pass_code('', 'rsync -aAXv --exclude={"/dev/*","/proc/*","/sys/*","/tmp/*","/run/*","/mnt/*","/media/*","/lost+found","/boot"} --delete')
$this->bbcode_second_pass_code('', 'umount /mnt/root')
Thats it. It t works very well. Ok, i have only one backup of my system and not a whole history like with ZFS-Snapshots or with TimeMachine. But this is ok for me in this case.
Marko