Migration of disks to new PC

Hi folks,
I am planning to upgrade my hardware to something little newer but I want to keep my drives and the software setup. I have currently a dual-boot setup as follows:

  • SSD 1: Fedora 37 & Win 10
  • HDD 1: LVM with encrypted luks for Fedora’s /home& NTFS partition for Win user data
  • HDD 2: backups (LVM, luks, ext4)

SSD1 has an EFI partition, a boot partition, and a LVM with encrypted luks containers for /, and /vbox (where I store vms). I am using grub 2 to boot the two os. This has been working absolutely flawlessly since 2016!

The machine is running in UEFI mode with secure boot disabled.

I wonder what happens to the UUIDs and block device naming (sdX) when I migrate those drives into a new machine.

I would appreciate any hints and tips on what to consider in advance. Please let me know what I need to think of when migrating to the new system. I’d really like to avoid reinstalling Fedora and Win10. Thanks.

1 Like

Theoretically the UUIDs would not change, and there is no reason for them to change since that is stored on the drives and within the file systems/partition tables.

On the other hand, the device names (sdX) may change depending upon the order in which the os configures the device (which is the reason UUIDs are now preferred for mounting, etc.).

If your system is configured to use UUIDs and/or file system LABELs for all the mounts and has been so for some time, including during the latest kernel upgrades, then there realistically should be no issues in moving the drive hardware between machines.

2 Likes

I am pasting here the output of lsblk:

NAME                                          FSTYPE      TYPE  MOUNTPOINT
sda                                                       disk  
├─sda1                                        ntfs        part  
├─sda2                                        vfat        part  /boot/efi
├─sda3                                                    part  
├─sda4                                        ntfs        part  
├─sda5                                        ntfs        part  
├─sda6                                        ext4        part  /boot
└─sda7                                        crypto_LUKS part  
  └─luks-3667a487-2cde-4f4c-b35a-5225ca21f846 LVM2_member crypt 
    ├─fedora00-root                           ext4        lvm   /
    └─fedora00-vbox                           ext4        lvm   /vbox
sdb                                                       disk  
├─sdb1                                        crypto_LUKS part  
│ └─luks-dcb1297c-8706-4b50-81ce-3f2fb6521bfa LVM2_member crypt 
│   └─fedora-home                             ext4        lvm   /home
└─sdb2                                        ntfs        part  
sdc                                                       disk  
└─sdc1                                        crypto_LUKS part  
  └─luks-d8f5face-d576-4bc7-85d3-c9870f0bccec LVM2_member crypt 
    └─backup-backup                           ext4        lvm   /backup
zram0                                                     disk  [SWAP]

and output of fstab:

# /etc/fstab
/dev/mapper/fedora00-root               /               ext4    defaults,x-systemd.device-timeout=0 1 1
/dev/mapper/backup-backup               /backup         ext4    defaults,x-systemd.device-timeout=0 1 2
UUID=41e507d5-6de3-43da-9de2-cc32e35de62b /boot ext4    defaults 1 2
UUID=3C24-01BC                          /boot/efi       vfat    umask=0077,shortname=winnt 0 2
/dev/mapper/fedora-home                 /home           ext4    defaults,x-systemd.device-timeout=0 1 2
/dev/mapper/fedora00-vbox               /vbox           ext4    defaults,x-systemd.device-timeout=0 1 2

#added swap space_2016-12-04
/swap/swapfile                                  swap    swap    defaults 0 0
/backup/swap/swapfile8                          swap    swap    defaults 0 0

#SSD optimization
none    /tmp/                                   tmpfs   size=5%         0 0

So, UUIDs are used. You think I am good just moving the disks to the new machine, connecting the in the same order on the SATA ports?

One more question, what about this “Microsoft reserved” partition (sda3), which is the only one that does not have a UUID? I don"t even know what that partition does - it’s not the “MS restore partition” (which is sda1 in my case).


NAME                                          FSTYPE      UUID                                     SIZE MOUNTPOINT
sda                                                                                              238,5G 
├─sda1                                        ntfs        CC121FC1121FAF86                         300M 
├─sda2                                        vfat        3A24-01AC                                100M /boot/efi
├─sda3                                                                                             128M 
├─sda4                                        ntfs        C8BC2842BC282D7E                        65,5G 
├─sda5                                        ntfs        C242791B427914FF                         553M 
├─sda6                                        ext4        41e507d5-6d33-4eda-9de2-ce3c235de62b     500M /boot
└─sda7                                        crypto_LUKS 3667a487-2cde-4f4c-b35a-5225ca21f846   171,4G 
  └─luks-3667a487-2cde-4f4c-b35a-5225ca21f846 LVM2_member Uwu6ZZ-TpHt-sJ5A-t7ya-0PdT-MGar-qdLVIu 171,4G 
    ├─fedora00-root                           ext4        521483f4-c7c6-416a-8637-8ac781e642e4      37G /
    └─fedora00-vbox                           ext4        0bdd5b97-7bac-4ca8-9e5c-6eb4bb1e1150   134,4G /vbox


Windows is sort of crazy, I just realized I have two MS restore partitions (sda1 and sda5)…

While I cannot speak to problems that may occur with windows, as far as I can tell the linux part should be OK.

As I understand it, windows on new hardware might be an issue since the licensing for windows seems tied to the hardware IDs. It probably will require a recovery procedure and possibly even purchasing a new license.

2 Likes

thanks for checking the info I provided @computersavvy!
I’ll do some research on the windows part - I wish I didn’t need it but that is another story.

Is there anything else I need to do beforehand in regards to the new hardware like onboard LAN adapter, GPU, or so, or will this all work since the kernel ships all drivers? New LAN adapter is a Realtek sucker, and GPU, as before, is AMD radeon.

Disk that are 7 years old have a high chance to fail given their age.
Especially if they are consumer and not enterprise spec drives.

1 Like

It may be true but I’m not worried because

  • they are good hard drives (not sure about the SSD)
  • they don’t have that many hours since this is my secondary machine
  • I have multiple backups of anything that’s important to me.
1 Like

I am reporting back that the migration of three disks into a new PC worked even smoother than expected.
I booted as if moving disks hadn’t even happened.

offtopic: Even my Win10 was able to boot from grub and did not ask for re-activation.