LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Ubuntu (http://www.linuxquestions.org/questions/ubuntu-63/)
-   -   12.4 new install grub 2 boot problem with grub put on it's own partition not on MBR (http://www.linuxquestions.org/questions/ubuntu-63/12-4-new-install-grub-2-boot-problem-with-grub-put-on-its-own-partition-not-on-mbr-4175439668/)

james2b 12-02-2012 04:03 AM

12.4 new install grub 2 boot problem with grub put on it's own partition not on MBR
 
I just installed a fresh Ubuntu 12.04 and during install selected to have grub put on it's own partition for the boot device, not on the MBR since I use the Windows 7 boot manager for my booting. I also boot Ubuntu version 10.04 with the 7 and 12.04. I use Easy BCD to configure the boot menu, and did add in my new 12.04, but when I select it to boot it re-directs to the 10.04 grub menu. So I added the 12.04 in the neo-grub option in Easy BCD which now does boot up 12.04. I did try to run; grub-install /dev/sda7 in a terminal which failed due to the use of blocklists. The 12.04 is on sda7, 10.04 on sda6, and windows 7 is on sda1. So how can I install a working grub 2 onto the root partition of 12.04 so it can be booted directly ?

syg00 12-02-2012 04:18 AM

Sounds like you are doing the right thing(s).
Explain this (more) fully - what messages do you get ?.
Quote:

I did try to run; grub-install /dev/sda7 in a terminal which failed due to the use of blocklists.
You should get the opportunity to override it and force the install to the partition boot record (been a while since I bothered with Ubuntu).

james2b 12-02-2012 04:48 AM

With that grub-install command in a terminal it just says can not continue due to block lists are unreliable and not recommended when attempting to install grub on the boot sector of Ubuntu root partition. But I have done that before with previous versions of Ubuntu.

tommcd 12-02-2012 09:27 AM

James2b,
Try downloading and running the bootinfo script: http://sourceforge.net/projects/bootinfoscript/
Untar it and run the script from any Linux that you can boot. I think you can even run it from a live CD if you can not boot any of your Ubuntus.
It will create a Results.txt file that you can post here in CODE tags here so it will be easier to read.
The bootinfo script will give very detailed info on what OSs and boot loaders you have installed and where they all are.
I am not very skilled at analyzing bootinfo script results; but many people here are and perhaps the results from bootinfo can help in diagnosing your problem.

If it were me, I would just install the grub2 from Ubuntu 12.04 to the MBR. This will easily detect your Ubuntu 10.04 and your Windows 7 so you can boot all 3 with no problem. This would be the easiest solution imo.

colorpurple21859 12-02-2012 09:47 AM

To install grub2 to a partition you have to force it by using -f or --force option

james2b 12-03-2012 12:46 AM

Okay thanks for the help, I did run that bootinfo script. This does not include my external esata drive which was connected and on, since it made the list too long, so here it is, and I did notice that msdos7 instead of a normal (hd0,7) for the 12.04 on sda7.

Code:

Boot Info Script 0.61      [1 April 2012]


============================= Boot Info Summary: ===============================

 => Windows is installed in the MBR of /dev/sda.
 => Grub2 (v1.97-1.98) is installed in the MBR of /dev/sdb and looks at sector
    1 of the same hard drive for core.img. core.img is at this location and
    looks in partition 3 for /boot/grub.

sda1: __________________________________________________________________________

    File system:      ntfs
    Boot sector type:  Windows Vista/7: NTFS
    Boot sector info:  No errors found in the Boot Parameter Block.
    Operating System:  Windows Vista
    Boot files:        /NST/menu.lst /boot.ini /bootmgr /Boot/BCD
                      /Windows/System32/winload.exe /ntldr /NTDETECT.COM

sda2: __________________________________________________________________________

    File system:      ntfs
    Boot sector type:  Windows XP: NTFS
    Boot sector info:  No errors found in the Boot Parameter Block.
    Operating System:  Windows XP
    Boot files:        /boot.ini /ntldr /NTDETECT.COM

sda3: __________________________________________________________________________

    File system:      ntfs
    Boot sector type:  Windows Vista/7: NTFS
    Boot sector info:  No errors found in the Boot Parameter Block.
    Operating System:  Windows 7
    Boot files:        /Windows/System32/winload.exe

sda4: __________________________________________________________________________

    File system:      Extended Partition
    Boot sector type:  -
    Boot sector info:

sda5: __________________________________________________________________________

    File system:      swap
    Boot sector type:  -
    Boot sector info:

sda6: __________________________________________________________________________

    File system:      ext4
    Boot sector type:  Grub2 (v1.97-1.98)
    Boot sector info:  Grub2 (v1.97-1.98) is installed in the boot sector of
                      sda6 and looks at sector 367314739 of the same hard
                      drive for core.img. core.img is at this location and
                      looks in partition 6 for /boot/grub.
    Operating System:  Ubuntu 10.04.4 LTS
    Boot files:        /boot/grub/grub.cfg /etc/fstab /boot/grub/core.img

sda7: __________________________________________________________________________

    File system:      ext4
    Boot sector type:  Grub2 (v1.99)
    Boot sector info:  Grub2 (v1.99) is installed in the boot sector of sda7
                      and looks at sector 416062001 of the same hard drive
                      for core.img. core.img is at this location and looks
                      for (,msdos7)/boot/grub on this drive.
    Operating System:  Ubuntu 12.04.1 LTS
    Boot files:        /boot/grub/grub.cfg /etc/fstab /boot/grub/core.img

sda8: __________________________________________________________________________

    File system:      ext2
    Boot sector type:  -
    Boot sector info:
    Operating System: 
    Boot files:       

sda9: __________________________________________________________________________

    File system:      ext2
    Boot sector type:  -
    Boot sector info:
    Operating System: 
    Boot files:       

sda10: _________________________________________________________________________

    File system:      ntfs
    Boot sector type:  Windows Vista/7: NTFS
    Boot sector info:  No errors found in the Boot Parameter Block.
    Operating System: 
    Boot files:       

sda11: _________________________________________________________________________

    File system:      vfat
    Boot sector type:  FAT32
    Boot sector info:  No errors found in the Boot Parameter Block.
    Operating System: 
    Boot files:


yancek 12-03-2012 09:48 AM

I'm not sure what the problem is. Your bootinfoscript clearly shows all the necessary files for Ubuntu 10.4 and 12.04 on their respective partitions, sda6 and sda7. In your initial post you indicate that your EasyBCD menu showed Ubuntu 12.04 in the menu and when you selected it, you went to the 10.04 menu. You then said you added 12.04 to the EasyBCD menu and are now able to boot 12.04. Does it still take you to the 10.04 menu before booting 12.04. I'm not really sure what you are trying to do but the above information would seem to indicate you need to make a change in the EasyBCD configuration as all the Ubuntu files are present on both partitions. Maybe that's the way EasyBCD works, I'm not really that familiar with it.

Quote:

I did notice that msdos7 instead of a normal (hd0,7) for the 12.04 on sda7.
That is not the problem as it is standard on some of the Grub2 version entries.
Your bootinfoscript seems to be missing some output that is standard such as fstab, blkid and other info.

colorpurple21859 12-03-2012 12:26 PM

Did you try the following: grub-install -f /dev/sda7

james2b 12-03-2012 09:50 PM

I did not yet try to force grub 2 install because I can boot the new 12.04 by 2 methods. I can use that Easy BCD utility neo-grub boot loader, or from chainload in my Ubuntu 10.04 grub menu which I added that in. So since the 12.04 does have grub 2 show up and available to boot, then it must be installed but some little item is not correct. That hard drive does have 3 bad sectors, (it's a Seagate 500 GB), but seams to work fine. For the 10.04 there is no msdos in the grub boot lines.

james2b 12-06-2012 07:47 PM

Yes when I select the 12.04 from at the Windows boot manager, it still re-directs to the 10.04 grub boot menu. And I did use the Easy BCD to delete and re-create the 12.04 boot entry.

colorpurple21859 12-06-2012 08:48 PM

Quote:

Yes when I select the 12.04 from at the Windows boot manager, it still re-directs to the 10.04 grub boot menu. And I did use the Easy BCD to delete and re-create the 12.04 boot entry.
Did you install 12.04 grub to it's on partition? If not that might be the problem.

yancek 12-06-2012 09:27 PM

Quote:

For the 10.04 there is no msdos in the grub boot lines.
That doesn't mean anything and has nothing to do with your problem. Look at your bootinfoscript output. Ubuntu 10.04 uses Grub version 1.97 - 1.98 while Ubuntu 12.04 uses 1.99. There were changes made in different versions. Some use msdos line, other don't. I also noticed that you have Grub v1.97-1.98 installed to the mbr of sdb yet your results.txt output doesn't show any information about sdb? Additionally, the results.txt output is not complete as there is no information on UUID, fstab, etc. which is generally there.

Have you been able to directly boot multiple Linux distros with EasyBCD previously? I'm not really familiar with the program and how it works.

james2b 12-07-2012 05:22 AM

I did have my external hard drive connected and running when I ran the boot info script, which has 5 or 6 Linux installed, but then that made the output list way too long to post in the forum, so I only copy and paste the sda internal drive. With this computer I have had only Ubuntu 10.04 booting since about 10-2010, with Vista, 7, and XP, so first try with more than 1 Linux useing the Windows boot manager. I was booting my older PC with grub and many Linux with XP, and booting that external connected by eSATA too. Thanks for the help.

colorpurple21859 12-07-2012 06:30 AM

I have easybcd installed and from what I can tell it creates a \boot\grub directory and subdirectory/files in windows based on what is found in a linux distro /boot/grub depending on what options you select when adding an entry. That maybe why the 10.04 grub2 comes up. If the grub.cfg is copied from 12.04 to windows \boot\grub, my guess is that would be the menu that will be seen. Easybcd uses grub4dos which is based on grub legacy and uses windows \NST\menu.lst for it's grub menu if you create the neo-grub entry.

yancek 12-07-2012 10:34 AM

I would suggest you take a look at the files colorpurple21859 mentions for EasyBCD. There may be options there you can change to have separate entries for each Ubuntu like the priority. I don't have it available so I can't check but based on the information you have provided, I don't see how making any changes to Grub can change things.


All times are GMT -5. The time now is 05:46 AM.