Here's an example of changing PARTUUID using util-linux fdisk utility: # truncate -s 200M /tmp/file-as-a.disk The current version of fdisk (2.35.2 in Fedora 32 repositories at the time of editing) from util-linux can do that too in expert mode, in fact, starting from util-linux v2.23, fdisk has been GPT-enabled. There's already an answer here on to show how to change PARTUUID of GPT partition using gdisk utility. (After changed PARTUUID to the original one, Windows successfully booted from the large disk.) The reason is that changing UUID of NTFS file system to the original one isn't enough for Windows + UEFI, you also need to change the PARTUUID of GPT partition - PARTUUID matter. In order to solve it, select "1) Copy original to backup", and if you are asked "Perform changes ? (y/n)" you press y.Ī short story: I never thought I will need to touch PARTUUID of GPT partition, until now, when I try to migrate Windows from a small disk to a large disk, Windows failed to boot on the large disk and it can't even be repaired automatically. Once UUID is modified, you may need to update grub.cfg and/or fstab so that you can boot successfully next time.Įxecute fsck and see a "There are differences between boot sector and its backup" message. Once UUID is located, change them, press F2 to save and exit. Press /, enter the UUID in reverse order (if blkid reported 1234-ABCD, then search CDAB3412) to search the UUID data on disk. The UUID string of FAT / exFAT looks like 1122-3344, UUID string of NTFS looks like 1122334455667788. Here's detail steps to modify raw data on disk using hexedit.īlkid, write down the UUID of filesystem to paper, or remember it. WARNING, it's dangerous to modify raw data on disk, and could lost data without careful operation. This is another story here, currently there're no utilities to modify the filesystem UUID of these filesystems (See reichhart's answer - the mlabel tool), but we can modify raw data on disk to do this. In case you wanna change the whole UUID of NTFS file system instead of -new-half-serial, use the -new-serial option. There's ntfslabel utility (thanks to ntfs-3g) to change UUID of NTFS file system. LUKS (cryptsetup)Ĭryptsetup luksUUID -uuid=$NEW_UUID $LUKS_DEVICEĬryptsetup luksUUID -uuid=e0c0e0c0-e0c0-e0c0-e0c0-e0c0e0c0e0c0 ~/encrypted-LUKS.loop NTFS file system
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |