User Tools

Site Tools


Sidebar






newpage

linux:backup

Backup

howtos for various backup systems…

Simple dd backup of a partition or (raspi) SD card

Only works, if SD Cards have the exact same size!! otherwise rootfs partition will be br0000ken. Use rsync in that case

Replace sdX with your SDcard (check fdisk -l)

dd bs=4M if=/dev/sdX | gzip -c9 > /home/your_username/image`date +%d%m%y`.gz

2. terminal:

watch progress

Restore:

gzip -dc /home/your_username/image....gz | dd bs=4M of=/dev/sdX

rsync from one SD card to another

create partitions.

mount partitions of both SDcards (here raspi rootfs):

mount /dev/sdx2 /mnt/source
mount /dev/sdx2 /mnt/target  

rsync:

rsync -av /mnt/source/ /mnt/target/

raspi boot fixes

#fixme make sdx1 bootable

adjust bootfs cmdline.txt to match PARTUUID of

blkid /dev/sdX1

if partition sdX2 does not have PARTUUID use UUID in cmdline.txt

linux/backup.txt · Last modified: 2024/07/17 17:56 by tkilla