vendredi 6 mars 2015

Backup partition changed UUID without user interaction


I recently had to purchase a new hard drive. Since I was at it I bought two instead of one as they were on offer (both are the same model). Since there was a lot of space left on the second hard disk I simply used it for a full scale backup of my root partition:



# single user mode.
# dd if=/dev/sda1 of=/dev/sdb3 bs=32M


After that I changed the UUID of the backed up partition and double-checked that it had a different UUID.



# tune2fs -U random /dev/sdb3


After that everything worked fine for some weeks, booting up each day and working as normal.


Recently, after booting up the computer, I suddenly had the backup partition (sdb3) as root, instead of my real root partition(sda1).


So, I shut down the computer, restarted and again, the backup partition. I modified the boot command line and booted directly to the correct device (sda1) and checked what was going on. I couldn't believe it, but the backup partition (sdb3) magically had the same UUID as the real root (sda1).


How could this happen (assuming no evil manipulations from an unknown third party)? Is it systemd? :)


I am running Debian testing, and this is a home computer where only I should have physical access.



Aucun commentaire:

Enregistrer un commentaire