Re: [gentoo-user] Why grub can't load win kernel

2011-10-05 Thread Mick
On Wednesday 05 Oct 2011 16:32:10 Lavender wrote:
> The configuration of win kernel in grub.conf is like below:
> 
>  rootnoverify (hd0,0)
>  makeactive
>  chainloader +1

Assuming that your MSWindows OS is on the first partition of the first (master) 
disk then the above is correct and grub should boot it fine;  i.e. MSWindows is 
on /dev/sda1


>  It worked yesterday , but after I rebuilding grub software, it can't work.
> I don't know why, it still can boot gentoo kernel, I am confused,because
> grub only can do operations to MBR, it can not influence contents on
> windows partition.

This is not entirely correct.  GRUB will write its boot code where-ever *you* 
tell it to write it ...

For example if you installed it on MSWindows' partition - instead of the disk 
MBR - you will most likely not be able to boot MSWindows!  This is because you 
have overwritten the partition table with GRUB's code and GRUB cannot natively 
boot MSWindows.

If for example you ran:

  grub-install /dev/sda1

instead of the correct stanza of:

 grub-install /dev/sda

you would have written GRUB on the wrong place, the first partition boot 
record, instead of the disk's Master Boot Record.  Of course your old GRUB 
code in the MBR is still there and it happily boots Linux.


>  I also tried boot manually in grub command interface, but after showing
> "load stage2" it goes back to grub >  I'm gonna pissed. I have
> many important things in windows system, will someone  figure it out?

Calm down.

Your data is still there.  Just the partition table has been overwritten - if 
indeed you typed the wrong device as I suspect above.  So the command you need 
is fixboot and you need to run this from a MSWindows installation CD/USB stick 
on the first partition.  

Have a look on the Internet for more details on the fixboot command and its 
modern equivalent (if you're running Windows7).  Also have a look on the 
Internet for MSWindows CDs or USB sticks to be able to run the command if you 
don't have one handy.

HTH.
-- 
Regards,
Mick


signature.asc
Description: This is a digitally signed message part.


Re: [gentoo-user] Why grub can't load win kernel

2011-10-05 Thread Jonas de Buhr
Am Wed, 5 Oct 2011 21:20:07 +0200
schrieb Alan McKinnon :

> > which of the grub USE flags do you think could cause this behavior?
> > 
> 
> I have no idea.
> 
> I'm asking for full fault report information, mentioning everything 
> I can think of that could be relevant. You know, the things one should
> mention in the first post instead of "stuff don't work. Why?"
> 
> 

yeah, there could have been more info included...



Re: [gentoo-user] Why grub can't load win kernel

2011-10-05 Thread Alan McKinnon
On Wed, 5 Oct 2011 18:26:31 +0200
Jonas de Buhr  wrote:

> Am Wed, 5 Oct 2011 17:39:59 +0200
> schrieb Alan McKinnon :
> 
> > What version of grub, and what options (USE flags) was grub built
> > with?
> 
> which of the grub USE flags do you think could cause this behavior?
> 

I have no idea.

I'm asking for full fault report information, mentioning everything 
I can think of that could be relevant. You know, the things one should
mention in the first post instead of "stuff don't work. Why?"


-- 
Alan McKinnnon
alan.mckin...@gmail.com



Re: [gentoo-user] Why grub can't load win kernel

2011-10-05 Thread Jonas de Buhr
Am Wed, 5 Oct 2011 23:48:09 +0800
schrieb "Lavender" <448463...@qq.com>:

> Sorry, I'm a gentoo newcomer, so I am totally not familar with this
> OS. Does USE make sense with grub ? And in the building there is no
> error, I had grub-install done. 

which was the *exact* commandline for grub-install? please copy it from
your shell history 

grep grub-install ~/.bash_history

and show us the output. also please send in the output of

fdisk -l

and your complete grub.conf

> Grub boot interface can show up , I
> can choose which OS to boot, but I couldn't boot win , what is the
> problem in your opinion? 
>   -- Original --
>   From:  "Alan McKinnon";
>  Date:  Wed, Oct 5, 2011 11:39 PM
>  To:  "gentoo-user"; 
>  
>  Subject:  Re: [gentoo-user] Why grub can't load win kernel
> 
>   
> On Wed, 5 Oct 2011 23:32:10 +0800
> "Lavender" <448463...@qq.com> wrote:
> 
> > The configuration of win kernel in grub.conf is like below:
> >   
> >  rootnoverify (hd0,0)
> >  makeactive
> >  chainloader +1
> >   
> >  It worked yesterday , but after I rebuilding grub software, it
> > can't work. I don't know why, it still can boot gentoo kernel, I am
> > confused,because grub only can do operations to MBR, it can not
> > influence contents on windows partition. I also tried boot manually
> > in grub command interface, but after showing "load stage2" it goes
> > back to grub >  I'm gonna pissed. I have many important
> > things in windows system, will someone  figure it out?
> 
> What version of grub, and what options (USE flags) was grub built
> with?
> 
> Any errors from the build of grub?
> (check /var/log/portage/elog)
> 
> Did you run grub-install like the ebuild tells you to do at the end?
> 



Re: [gentoo-user] Why grub can't load win kernel

2011-10-05 Thread Jonas de Buhr
Am Wed, 5 Oct 2011 17:39:59 +0200
schrieb Alan McKinnon :

> What version of grub, and what options (USE flags) was grub built
> with?

which of the grub USE flags do you think could cause this behavior?



Re: [gentoo-user] Why grub can't load win kernel

2011-10-05 Thread Lavender
Sorry, I'm a gentoo newcomer, so I am totally not familar with this OS. Does 
USE make sense with grub ? 
 And in the building there is no error, I had grub-install done. Grub boot 
interface can show up , I can choose
 which OS to boot, but I couldn't boot win , what is the problem in your 
opinion?
   
  
  -- Original --
  From:  "Alan McKinnon";
 Date:  Wed, Oct 5, 2011 11:39 PM
 To:  "gentoo-user"; 
 
 Subject:  Re: [gentoo-user] Why grub can't load win kernel

  
On Wed, 5 Oct 2011 23:32:10 +0800
"Lavender" <448463...@qq.com> wrote:

> The configuration of win kernel in grub.conf is like below:
>   
>  rootnoverify (hd0,0)
>  makeactive
>  chainloader +1
>   
>  It worked yesterday , but after I rebuilding grub software, it can't
> work. I don't know why, it still can boot gentoo kernel, I am
> confused,because grub only can do operations to MBR, it can not
> influence contents on windows partition. I also tried boot manually
> in grub command interface, but after showing "load stage2" it goes
> back to grub >  I'm gonna pissed. I have many important
> things in windows system, will someone  figure it out?

What version of grub, and what options (USE flags) was grub built with?

Any errors from the build of grub?
(check /var/log/portage/elog)

Did you run grub-install like the ebuild tells you to do at the end?

-- 
Alan McKinnnon
alan.mckin...@gmail.com

Re: [gentoo-user] Why grub can't load win kernel

2011-10-05 Thread Alan McKinnon
On Wed, 5 Oct 2011 23:32:10 +0800
"Lavender" <448463...@qq.com> wrote:

> The configuration of win kernel in grub.conf is like below:
>   
>  rootnoverify (hd0,0)
>  makeactive
>  chainloader +1
>   
>  It worked yesterday , but after I rebuilding grub software, it can't
> work. I don't know why, it still can boot gentoo kernel, I am
> confused,because grub only can do operations to MBR, it can not
> influence contents on windows partition. I also tried boot manually
> in grub command interface, but after showing "load stage2" it goes
> back to grub >  I'm gonna pissed. I have many important
> things in windows system, will someone  figure it out?

What version of grub, and what options (USE flags) was grub built with?

Any errors from the build of grub?
(check /var/log/portage/elog)

Did you run grub-install like the ebuild tells you to do at the end?

-- 
Alan McKinnnon
alan.mckin...@gmail.com



[gentoo-user] Why grub can't load win kernel

2011-10-05 Thread Lavender
The configuration of win kernel in grub.conf is like below:
  
 rootnoverify (hd0,0)
 makeactive
 chainloader +1
  
 It worked yesterday , but after I rebuilding grub software, it can't work. I 
don't know why, it still can boot
 gentoo kernel, I am confused,because grub only can do operations to MBR, it 
can not influence contents on windows
 partition.
 I also tried boot manually in grub command interface, but after showing "load 
stage2" it goes back to grub >  I'm 
 gonna pissed. I have many important things in windows system, will someone 
 figure it out?