3

My server is running Ubuntu 12.04 LTS from /dev/sda3 (ext4). I experimented with CentOS 7 some time ago and that is on /dev/sda2 (xfs) and its grub is used for booting. It showed only the latest Ubuntu version in the grub menu, but that is fine.

I want the move from Ubuntu to CentOS to be smooth and first put some of the complicated services in docker containers.

Then I found docker runs only with vfs on the 3.16 So I downgraded to 3.13 As some recommended, rebooted in CentOS, ran update-grub, and rebooted. Now no entries for Ubuntu are shown.

I have restored the grub-menu from backup and can boot into Ubuntu again (but the newer kernel). How to have CentOS generate the Ubuntu kernel entries?

1

I think you are right to try and keep CentOS to boot if you want to move there, but you could of course try and see if CentOS is recognised by Ubuntu (grub-mkconfig under Ubuntu) and if it does (it should) run grub-update on Ubuntu and then grub-install /dev/sda.

The whole problem arises by distros making changes to /etc/grub.d/10-linux for their own older versions (copying with how they use Btrfs subvolumes, LVM and other distro specific peculiarities). If you compare that file from Ubuntu with CentOS you will see that there are huge differences.

What I have done in such situations is copy /etc/grub.d/10-linux form the old system to /etc/grub.d/11-<old_distro_name> on the new system and then run grub-mkconfig/update-grub on the new system. This can give you some double menu entries, but that is IMHO better than having too few of them.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.