Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 4954

Advanced users • What are the right ways to compare sd cards after cloning?

$
0
0
I searched the internet and this forum, and found some information, but I am not sure is it right or not.

1. I can use checksum for sda1 and sdb1 (sda2 and sdb2). Something like sha512sum /dev/sda2 and sha512sum /dev/sdb2 and compare the results. But this only works, if I made 100% clone (with something like dd) and didn't mount compared partitions after cloning.

2. I can use cmp, if I made 100% clone (cmp /dev/sda2 /dev/sdb2). As far as I understand, it should show empty result, if the partitions (files) are the same.

3. I can mount the partitions and compare all files on them, using diff -qr /media/mountpoint1 /media/mountpoint2 (As far as I understand, it should show empty result, if all files on the partitions are the same). But I am not sure, if I can mount two partitions with the same UUID without any harm for the partitions and files on them (mount /dev/sda2 /media/mountpoint1 and mount /dev/sdb2 /media/mountpoint2).

Statistics: Posted by POPEYE — Wed May 08, 2024 9:24 am



Viewing all articles
Browse latest Browse all 4954

Trending Articles