[SOLVED] Slackware on VirtualBox, can't upgrade GRUB
Linux - Virtualization and CloudThis forum is for the discussion of all topics relating to Linux Virtualization and Linux Cloud platforms. Xen, KVM, OpenVZ, VirtualBox, VMware, Linux-VServer and all other Linux Virtualization platforms are welcome. OpenStack, CloudStack, ownCloud, Cloud Foundry, Eucalyptus, Nimbus, OpenNebula and all other Linux Cloud platforms are welcome. Note that questions relating solely to non-Linux OS's should be asked in the General forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I tried to add an MBR to the current partition, but I shrunk it too far and it refused to boot. So, I just did a complete reinstall, included an MBR, and it installed lilo and works fine now.
Thanks all - I learned a few things about virtual environments, and we fixed my current setup.
Do you mean a BIOS_boot partition referred to earlier? The MBR is at the beginning of a disk and outside any partition. A simple edit of the grub.cfg file suggested above would have resolved the problem. If you are familiar with Lilo or Elilo, best to stick with it unless you like adventures and frustrations. Good luck with it.
Do you mean a BIOS_boot partition referred to earlier? The MBR is at the beginning of a disk and outside any partition. A simple edit of the grub.cfg file suggested above would have resolved the problem. If you are familiar with Lilo or Elilo, best to stick with it unless you like adventures and frustrations. Good luck with it.
I still don't quite get this, and I'm happy to keep talking if you want to keep explaining.
* Nothing I did to grub.cfg *ever* changed any my boot options. Defaults, skipping menus, etc.
* The MBR *can* be a partition - that's how I got lilo installed, is I created one by hand during the initial partition of the virtual disk. I don't usually have to do that on physical drives, but that's what worked here.
So do you have any thoughts about *why* edits to grub.cfg did nothing to my boot options?
So do you have any thoughts about *why* edits to grub.cfg did nothing to my boot options?
No, I was hoping the set command at the grub prompt would give insight into what was happening, but I guess we will never know now, unless Yancek has some insight into what the problem may have been.
Quote:
* The MBR *can* be a partition - that's how I got lilo installed, is I created one by hand during the initial partition of the virtual disk.
If this is a gpt drive I think I know what your talking about, if this is a msdos drive not so much, will you post the layout of the disk indicating what you are calling the mbr partition.
Last edited by colorpurple21859; 11-23-2023 at 09:13 AM.
* The MBR *can* be a partition - that's how I got lilo installed
No, for more details read the information at the link below. The MBR is outside any partitions created and is in the first sector of the drive, sector 0. If you have a GPT drive then you need to create an unformatted 1MN partition labelled as bios_boot in order to do a Legacy install on that drive.
Did you create an EFI partition on which you put elilo? An EFI install of Slackware will put EFI files on that partition as well as the kernel and initrd files. There is also a PBR (partition boot record) which is on the partition where an OS is installed and that OS can be chainloaded from another bootloader. If boot code is installed in the PBR, it will not boot unless there is another bootloader installed in either the MBR or an EFI partition.
Quote:
My concern with that is that /dev/nvmme0n1p6 is my physical disk, not the virtual one
That was only an example from my system and the /dev/nvmme0n1p6 should have been changed on your system to /dev/sda1.
At least one of the errors you reported "canonical path of cow" indicate you are trying to write to or make changes on a read only system, the iso file rather than the installed system. That would explain why changes did not take effect in grub.cfg. I believe the problem was that you tried to do what is called a Legacy install on a GPT drive before creating a bios-boot partition which is required for the grub core.img file. On a GPT drive, it is much better to install in EFI mode which should create an EFI partition for the proper boot files.
Quote:
the grub.cfg file is split into sections
No, it isn't. There are numerous Grub files which you can see in different locations by running "whereis grub" (without quotes) from a terminal. The grub.cfg file contents display what you see on screen when you boot. If you want permanent changes, you need to edit the various other Grub files and run grub-mkconfig.
Quote:
So do you have any thoughts about *why* edits to grub.cfg did nothing to my boot options?
Go back to post 7 and read the error reported. You did a Legacy/MBR type install with no bios_boot partition so it would not boot regardless of any changes you made.
If you got it working on the GPT drive, you would have had to either create a bios-boot or EFI partition.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.