LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-16-2017, 09:19 AM   #1
sigma957
Member
 
Registered: Sep 2003
Location: Portland Oregon
Distribution: Debian Testing
Posts: 112

Rep: Reputation: 15
Question Boot problem with grub/Debian/Mint


I run Debian testing on my machine. I had a free partition so I tried to install Linux Mint 18.1. It installed grub but now the Mint install isn't working. I have a Debian grub on my second hard drive.

I want to run the bootloader from Debian. I have two hard drives.

Here is the link to the bootinfoscript.

http://pastebin.ubuntu.com/23810781/

What do I need to do from Debian to get rid of the Mint/Ubuntu bootloader?

Thanks
 
Old 01-16-2017, 09:24 AM   #2
wagscat123
Member
 
Registered: Jan 2009
Location: Maryland-Pennsylvania border, USA
Distribution: openSUSE 15.2/15.3, Tumbleweed, Kubuntu 18.04/21.04, macOS 10.15, antiX 19, and Linux Mint 19.3
Posts: 860
Blog Entries: 45

Rep: Reputation: 120Reputation: 120
Your best bet to remove the Mint/Ubuntu option easily is probably GRUB Customizer: http://www.linuxserve.com/2015/05/ho...er-406-in.html
 
Old 01-16-2017, 01:49 PM   #3
Brains
Senior Member
 
Registered: Apr 2009
Distribution: All OS except Apple
Posts: 1,591

Rep: Reputation: 389Reputation: 389Reputation: 389Reputation: 389
Have you tried running command: sudo update-grub from within Debian?
By rights, grub will look for vmlinuz and initrd in other partitions and should find Mint's and configure it properly.

EDIT: From within Debian, run command: sudo fdisk -l to find the name of the Debian drive, then install grub to it with command: sudo grub-install /dev/sd(?) before running update-grub command. Install grub to where it should be either the partition or the drive on the Debian side. You may not need to run update-grub as the install should find Mint. By doing the install in Debian you are configuring grub to use Debian's grub boot configuration.

Last edited by Brains; 01-16-2017 at 02:03 PM. Reason: Added info
 
Old 01-16-2017, 06:29 PM   #4
sigma957
Member
 
Registered: Sep 2003
Location: Portland Oregon
Distribution: Debian Testing
Posts: 112

Original Poster
Rep: Reputation: 15
drive sdb has an EFI partition. I have to boot to that drive to get the debian grub. Why is it there? I've tried installing it to sda and the ubuntu one is still there. My bios shows debian and ubuntu as boot options. But if I select debian, it doesn't work. If I select the second drive, then it finds the debian grub.

What is EFI?

Thanks.
 
Old 01-16-2017, 07:33 PM   #5
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,361

Rep: Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591
Did you try to install debian grub to sdb?
 
Old 01-16-2017, 11:00 PM   #6
Brains
Senior Member
 
Registered: Apr 2009
Distribution: All OS except Apple
Posts: 1,591

Rep: Reputation: 389Reputation: 389Reputation: 389Reputation: 389
In short, UEFI is the new way of doing things as part to overcome old BIOS limitations. A quick google search can give you the lowdown, so I need not explain further.
Normally, the first drive will have the EFI partition.
Quote:
sdb1: __________________________________________________________________________

File system: vfat
Boot sector type: -
Boot sector info: No errors found in the Boot Parameter Block.
Operating System:
Boot files: /efi/debian/grubx64.efi /efi/ubuntu/fwupx64.efi
/efi/ubuntu/grubx64.efi /efi/ubuntu/MokManager.efi
/efi/ubuntu/shimx64.efi
According to the quote above from your configuration file, you have four Ubuntu and one Debian boot files, non of which mention Mint, but according to the same file grub for Mint is installed in the MBR of the first drive.
Just taking a guess here, but did you switch out the original drive with a new one without partitioning the new one GPT?
Tell the whole story regarding all the Ubuntu boot files in /dev/sdb, if they belong to old installations that don't exist, they should be removed.
Quote:
My bios shows debian and ubuntu as boot options
How many Ubuntu does the bios offer?
Since Mint is installed in BIOS mode, and Debian in UEFI mode, coupled with all those extra boot options, it's easy to see how it's hard to make sense of your posts. If you want to boot Debian, switch computer settings to UEFI instead of legacy BIOS. If the drive with the EFI partition was the first drive it would be easier to get one's head around this. I'm guessing you just need to swap the SATA cables of the drives to make it the first or it is done in settings, then reinstall Ubuntu in UEFI mode.
EDIT: If you can boot into one of them, preferably Debian, run command: efibootmgr to display what the computer's firmware sees, and post it.
ANOTHER EDIT: If you can get into Debian, run the grub-install command to the Debian partition, something like: grub-install /dev/sdb2 or sda2 if you set the drives in proper order first, it might enable Mint also, but you need to set the computer to UEFI mode first.

Last edited by Brains; 01-16-2017 at 11:26 PM.
 
Old 01-17-2017, 03:47 AM   #7
Brains
Senior Member
 
Registered: Apr 2009
Distribution: All OS except Apple
Posts: 1,591

Rep: Reputation: 389Reputation: 389Reputation: 389Reputation: 389
sdb2/boot/grub/grub.cfg:
According to this section highlighted above of the boot info script you provide. The Debian Stretch grub.cfg file has already found and is configured to boot:
Code:
Debian GNU/Linux, with Linux 4.8.0-1-amd64 (Stretch /dev/sdb2)
Debian GNU/Linux, with Linux 4.8.0-2-amd64 (Stretch /dev/sdb2)
Debian GNU/Linux, with Linux 3.16.0-4-amd64 (Jessie kernel? /dev/sdb2)
Debian GNU/Linux, with Linux 3.16-3-amd64 (Jessie kernel? /dev/sdb2)
Debian GNU/Linux, with Linux 3.16-2-amd64 (Jessie kernel? /dev/sdb2)
Arch (on /dev/sda11)
Linux Mint 17 Qiana (17) (on /dev/sda2)
Debian GNU/Linux, with Linux 3.14-1-amd64 (on /dev/sda7)(Jessie)
Debian GNU/Linux, with Linux 3.2.0-4-amd64 (on /dev/sda7)(Jessie)
Arch1 (on /dev/sda8)
Because it's /etc/fstab and grub.cfg goes by UUID of the partitions, swapping the order of the drives should not have any ill effect other than booting up the Arch installations as their fstab do not use UUID, which can easily be edited, but it looks like it's been this way for a while so it might not be necessary to swap them for the firmware to work.
There is no mention anywhere of Mint having a /boot/grub/grub.cfg, suggesting the grub in the MBR of sda is from your attempt to install grub to sda from Debian, which would also explain why Debian Stretch grub.cfg has all those OSs listed as menu entries, and also suggesting grub was not installed in Mint.

What is confusing, is how you mention getting Debian and Ubuntu in BIOS menu, if this is a UEFI system, those are likely to be the boot files in the EFI partition of the second drive which I quoted earlier, thus it is necessary to point to the second drive. Although, one would think, if the computer is set to boot the first drive in Legacy BIOS mode, grub would pop up and go straight to the Debian partition in the second drive to boot it when selected, it sounds like you say this does not work, meaning the UEFI firmware may prevent this from happening, or you have it set to UEFI instead of Legacy BIOS trying to boot sda which requires Legacy mode. Some computers also have UEFI with CSM, which if I got it right, allows booting both, my laptop pukes when I use this setting.

You have yet to mention if this is a UEFI system, so hopefully this post will help. Since there is no sign of Windows being installed and if it is a UEFI system (which sounds like it is), you can go either way, set it to boot in Legacy BIOS mode and select the first drive with grub installed to the MBR from within Stretch, or set it to UEFI and reinstall grub to Debian Stretch in /dev/sdb2. Probably better to go the Legacy BIOS mode which may eliminate the need to go through BIOS menu.
 
1 members found this post helpful.
Old 01-17-2017, 10:50 PM   #8
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, MX 18
Posts: 9,484
Blog Entries: 15

Rep: Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176
Boot into Debian become root 'su' and 'update-grub'and reboot:-

-::-You should be able to use the arrow keys to choose which os you want to boot into.-::-

If you still can't boot into Mint after that; launch g-parted in Debian and tell us if the Mint partition (which should be a ext 3 or 4 partition) is flagged 'bootable' or not?
 
Old 01-17-2017, 10:54 PM   #9
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, MX 18
Posts: 9,484
Blog Entries: 15

Rep: Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176
Quote:
Originally Posted by colorpurple21859 View Post
Did you try to install debian grub to sdb?
If he did it failed-
Code:
No boot loader is installed in the MBR of /dev/sdb.
 
Old 01-18-2017, 05:08 AM   #10
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,361

Rep: Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591Reputation: 1591
depends on if the op was in bios mode or efi mode and which disk the running system is calling sdb
 
1 members found this post helpful.
Old 01-18-2017, 06:50 PM   #11
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, MX 18
Posts: 9,484
Blog Entries: 15

Rep: Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176
Quote:
Originally Posted by colorpurple21859 View Post
depends on if the op was in bios mode or efi mode and which disk the running system is calling sdb
Got it:-

At this point we don't know if BIOS was set to UEFI.
That may be the case if an efi partition was created instead of MBR.

Having another look at the bootinfo. script Mint is on /dev/sda2 as an Ext 4 partition. Debian is on /dev/sdb2.

I'm thinking that updating Grub should help.
That is if Debian boots.

Last edited by Ztcoracat; 01-18-2017 at 06:55 PM.
 
Old 01-24-2017, 02:59 AM   #12
aragorn2101
Member
 
Registered: Dec 2012
Location: Mauritius
Distribution: Slackware
Posts: 567

Rep: Reputation: 301Reputation: 301Reputation: 301Reputation: 301
Quote:
Originally Posted by Brains View Post
What is confusing, is how you mention getting Debian and Ubuntu in BIOS menu, if this is a UEFI system, ...

You have yet to mention if this is a UEFI system ...
Exactly.

I know UEFI systems quite well, so I might help here. I have a UEFI laptop and I also have a BIOS PC on which I installed a GPT hard disk. The GPT hard disk cannot be used to boot any OS since the PC is BIOS, so I boot from a smaller MBR disk.

So, sigma957, please shed some light here. Give us more details about your system and how did you proceed to install these Mint and Debian.
 
Old 01-24-2017, 06:51 AM   #13
yancek
LQ Guru
 
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 10,534

Rep: Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495Reputation: 2495
Your first drive where you seem to have Mint installed, is an MBR drive with Grub code in the master boot record pointing, probably? to Debian on sda7. Your second drive with one of the Debian installs, is EFI with GPT partitioning. Mixing MBR and EFI is almost always problematic although I understand it is possible to do by selecting a specific drive from the BIOS on boot.

If you look at the grub.cfg file for the newer Debian on sdb2, it shows entries for it's partition, for Arch and Mint on sda as well as the other Debian install on sda7. Also, note that the menuentries for Debian on sdb2 show it as gpt while the other systems on sda all show msdos (MBR) partitions. I don't think that will work. You can boot Linux systems with MBR/GPT partitioning if you have a separate BIOS boot partition. You need to decide whether you are going to use EFI or not.

I agree with the above post about the EFI partition being on the second drive. Unusual for sure.

I don't think the Mint EFI files are named Mint but rather say ubuntu so I expect those ubuntu files on the EFI partition are the Mint files.

Quote:
What is EFI?
Read the link at the Ubuntu documentation site below. Would have been more useful if you had read it before installing Mint, but...

https://help.ubuntu.com/community/UEFI
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Dual boot jessie/mint lvm, grub shows debian and mint, all only boot debian slacker_ Debian 12 03-12-2015 01:13 AM
GRUB boot menu does not appear after installation of Mint 15 mikebaiduu Linux - Newbie 2 12-30-2013 07:01 PM
[SOLVED] Grub Error with Mint Debian over Ubuntu 12.04 with Win7 Dual Boot Grub Error Gad Linux - Newbie 8 07-01-2013 08:31 PM
Boot problem with Debian (grub) and hardware RAID 1 kampmannpeine Debian 2 11-07-2010 06:40 AM
Debian windows installer GRUB dual boot problem zerocle Debian 16 02-04-2007 03:34 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:36 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration