1

I have 500gb of HDD, my partition are like this

  1. 80 GB windows (primary partition) /dev/sda1
  2. 80 GB ubuntu 12.04 (primary partition) (/dev/sda2)
  3. and remaining extended partition of >300 GB (/dev/sda4)

my motherboard is efi compatible, initially i installed window in efi mode of bios, after a lot workaround of installing dual boot system in efi mode i switched back to legacy mode

I installed ubuntu 12.04 after switching back to legacy mode and every time i start my system windows xp start. I tried to rewrite grub from live cd these are the commands i got from many site

sudo mount /dev/sdx /mnt
sudo grub-install --root-directory=/mnt/ /dev/sdx

I have rewrite grub in /dev/sda which is root of my hdd and then i wounded up with following error "no such partition grub rescue" i googled for this error and got many things to do but before doing further action on this i thing error is because of switching from efi to legacy. Should i format my hdd and with raw hdd, first i should install window and then ubuntu.

my question is: how efi and legacy BIOS maintain MBR record ?

2
  • Try running the Boot Info Script from a Linux live CD. This will generate a file called RESULTS.txt. Post it to a pastebin site and post the URL that it spits out here. This will give us detailed information on your system.
    – Rod Smith
    Oct 20, 2013 at 16:26
  • after getting error of "no such partition grub rescue" i then uninstalled ubuntu from my system, and after your comment i reinstalled ubuntu and i had run the above tar file and got the following RESULTS.txt Oct 21, 2013 at 19:39

2 Answers 2

0

you could try

sudo grub-install /dev/sda2

Or you could try using liveCD or USB to use boot-repair https://help.ubuntu.com/community/Boot-Repair

2
  • if he switched to Legacy mode, then for sure sudo grub-install /dev/sda2 will not work.
    – LovinBuntu
    Oct 20, 2013 at 22:43
  • i'm also sure of this command will not work, since partition table created by MBR (BIOS) and UEFI (GPT) are different, i only want to know how my hard is formatted right now ? Oct 21, 2013 at 19:49
0

First, please clarify what you mean by:

I have rewrite grub in /dev/sda which is root of my hdd and then i wounded up with following error "no such partition grub rescue"

If you mean that you're getting a GRUB rescue prompt when you boot the computer, then there's something wrong with your GRUB configuration. Chances are it's the fact that the Boot Info Script is saying that GRUB is looking on /dev/sda1 (an NTFS partition) for its configuration file. It was probably an error in your manual GRUB installation that caused this problem. Running Boot Repair is likely to be the easiest way to fix this problem.

If you're still booting straight to Windows, try checking your firmware's boot options concerning which disk to boot. GRUB is installed in the first disk (/dev/sda), but if your firmware is set to boot from the second disk (/dev/sdb), that might explain a boot direct to Windows. If this is your problem and you fix it, though, you'll probably end up with GRUB problems and need to run Boot Repair, as just described.

2
  • sorry for not mentioning about what message now i get after reboot (after installing ubuntu again to run above script), as system starts now i don't get above error "no such partition grub rescue" message, instead i get the screen where there is some text written at top of console and there is something like this "grub>" and after pressing tab button i get many available command for that screen eg. blocklist, etc, can you say what this means and thanks you for helping me Oct 23, 2013 at 4:50
  • As I said, run Boot Repair on the system.
    – Rod Smith
    Oct 23, 2013 at 15:32

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .