🔍 See Original Answer on Ask Ubuntu ⧉ 🔗
Fully Move Grub to New Partition
October 28, 2018
Edited: June 12, 2020
September 20, 2023
Copy to clipboard: false
/assets/js/search.js will update text..
256 MB for
/boot and 200 GB for
You have lots of space but
/boot directory is “space challenged”. I’d suggest moving
Your current plan of moving
/boot to new partition
sdb7 which is only 512 MB seems limited. Sometimes my
/boot can be many GB if I’m testing out multiple kernels.
How to move
There is already an answer here:
Yes it is possible. Also its not easy. If you intent to move separated /boot partition and or / partition you should consider first of all changing the fstab entries.
If you are moving the files to new partition then don’t forget to use
cp -p while copying to preserve permissions. adjust then your
/etc/fstab to the new UUID’s of partitions that you will use. YOu can get the partition uuid by running
blkid /dev/sdXn where X is name of the drive and n number of partition.
You can also use blkid to attach labels to your partitions and then mount via labels which is much easier read
man blkid to learn more.
After you change the partitions and adjust /etc/fstab you should run the
update-grub - available on Debian/Ubuntu script or
grub-mkconfig -o /boot/grub/grub.cfg to generate a new config file and then reinstall grub into the first hdd that you bot from.
grub-install --recheck /dev/sdb
Of course do not forget that when copiying mount a new / or /boot partition on /mnt and after copying all of the files mount them as / and /boot chroot and only then run update of the grub if you want things to be done correctly.