I installed my brand new RB5 with an nvme drive and I'm really happy with that.
Now I want to partition the nvme a bit in order to have separated home partition.
What is the best approach?
- Boot from an SD card or USB drive (you may have to change your bootloader config to enable this).
- Make sure the partitions on the NVMe drive are not mounted
- Run gparted (you might have to install that from apt first)
- Select the NVMe drive
- Reduce the size of its second partition
- Create a new partition formatted to ext4 in the now empty space
- Apply changes
- Shutdown
- Remove SD card/USB drive
- Boot
- Copy the existing home directories:
- Mount the third partition of the NVMe drive on /mnt. Desktop users may have to unmount/eject it from where the automounter put it first.
Code:
sudo rsync -axrvH /home/* /mnt/
- Add an entry for the new partition to your /etc/fstab to mount it on /home (Hint: Using fstab A Beginner's Guide)
- Reboot
Next time I need to reinstall the OS will my partitioning scheme be respected?
Depends. If you follow the usual method and write a .img to the drive (or use SD card copier) your partition table will be replaced as will all references to your data.
Statistics: Posted by thagrol — Wed Mar 13, 2024 4:32 pm