I tried to replace the HDD in my Ubuntu PC with a new SSD for the performance improvement.
Please backup your data before starting the following processes.
It is assumed that you have already installed a new storage HW into your PC. Also, Ubuntu live USB is required.
5. Select the target device and paste the copied partition. If the device is in the first use, you need to create a new partition table before the paste. I chose
msdos that was identical to original partition’s. I checked it in the
/boot/grub/grub.cfg file. Also, you can resize the pasted partition as you want.
8. Re-install GRUB. If your partition is a boot partition. Check the new device name and the new partition name. For example, in my case, the new device(SSD) name was
/dev/sdc and the partition name was
/dev/sdc1. Run the following commands in a terminal.
sudo mount /dev/sdc1 /mnt sudo grub-install --root-directory=/mnt /dev/sdc sudo umount /mnt
9. Change the
UUID of the original partition with the following command. The
random parameter will generate a new random
(This process is required because
gparted copies all the data in a partition including
UUID. You can find
UUID of each partition with the
sudo blkid command. The same
UUID in two different partitions will confuse your operating system.)
sudo tune2fs /dev/sdc1 -U random
10. Reboot with the new partition. You might need to change the boot priority option in the BIOS.