Replacing M.2 system drive (btrfs) on motherboard with single slot
I finally have the budget to build my first NAS and upgrade my desktop PC. I have used Linux for quite some time, but am far from an expert.
One of the steps is to move my M.2 NVME system drive (1TB) from my desktop to my NAS. I want to replace it with a bigger NVME drive (2TB). My current motherboard only has a single M.2 slot, that’s why I bought a M.2 enclosure.
My goal is to put my new drive into the enclosure, clone my whole system disk onto it and then replace the old drive. At first I found several posts about using clonezilla to clone the whole drive, but some posts mentioned it not working well with btrfs (/ and /home subvolume), which is the bulk of my drive.
I have some ideas how I might to pull it off. My preliminary idea is:
- clone my boot partition with clonezilla
- use btrfs-clone or moving my butter to transfer the btrfs partition
- resize the partitions with gparted (and add swap?)
The two aspects I’m uncertain about are:
- UUIDs
- fstab
I plan to replace the old drive, so the system will not have two drives with the same UUID. If the method results in a new UUID I need to edit fstab.
As you can see I’m not sure how to proceed. Maybe I can just use clonezilla or dd to clone my whole drive? If someone has experience with such a switch or is just a lot for familiar with the procedures, I would love some tips and insight.
Thanks for reading.