Jump to content











Photo
- - - - -

boot grub


  • Please log in to reply
58 replies to this topic

#1 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 10:00 AM

hello,

I have an usb multiboot key with memtest86, dos... but i want to have a possibility on the menu.lst : boot directly to my harddrive. (In my hardrive I have a multiboot because i have got linux and windows.) What can I do ?

boot -> usb -> grub4dos(usb) -> grub(HD)

Sorry if my english is bad.. I'm a french student.


#2 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 10:51 AM

this don't work :

title GNU/Linux
kernel (hd1,0)/vmlinuz root=/dev/hdb1

#3 maanu

maanu

    Gold Member

  • Advanced user
  • 1134 posts
  •  
    Pakistan

Posted 25 August 2009 - 10:57 AM

this don't work :

title GNU/Linux
kernel (hd1,0)/vmlinuz root=/dev/hdb1


boot mbr of the 1st hdd directly ? from usb

title MBR of 1st hdd (from usb )

checkrange 0x80 read 0x8280 && map (hd1) (hd0)

checkrange 0x80 read 0x8280 && map --hook

chainloader (hd0)+1


#4 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 11:13 AM

THANKS FOR REPLY but I have an error :

starting cmain()... no pxe stack


what the program do : menu.lst -> title MBR of 1st hdd (from usb ) -> error -> menu.lst

#5 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 11:25 AM

boot mbr of the 1st hdd directly : yes i want

#6 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 11:53 AM

can you help me ? If i'm not understood, i can re-write.. :D

#7 maanu

maanu

    Gold Member

  • Advanced user
  • 1134 posts
  •  
    Pakistan

Posted 25 August 2009 - 12:15 PM

can you help me ? If i'm not understood, i can re-write.. :)


sure . i want to help u .

1. can u see the new entry in menu.lst ?
2. when u boot ur usb drive, is menu.lst appears or at that stage it gives the above "no pxe stack " error ?
3. can u note the above entries i mentioned somewhere like on ur mobile phone , and when u boot ur usb drive , keep pushing " C " . it ll lead u to command line interface , from there enter entries one by one , like

checkrange 0x80 read 0x8280 && map (hd1) (hd0)

ENTER

then

checkrange 0x80 read 0x8280 && map --hook

ENTER

then

chainloader (hd0)+1

ENTER

then

boot

ENTER .

what is the output ?

#8 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 01:21 PM

thanks a lot. the error was after type "boot"

#9 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 01:38 PM

checkrange 0x80 read 0x8280 && map (hd1) (hd0)

->Addresse 0x8280: Value 0x410a0fb

checkrange 0x80 read 0x8280 && map --hook

->Addresse 0x8280: Value 0x410a0fb

chainloader (hd0)+1

->back to line

boot

->Try (hd0,0) : fat 32 :
->starting cmain()... no pxe stack

...back to the menu

#10 maanu

maanu

    Gold Member

  • Advanced user
  • 1134 posts
  •  
    Pakistan

Posted 25 August 2009 - 02:54 PM

do u also have installed grub4dos to ur hdd ?

if yes , then which hdd ? and in which partition u have grldr and menu.lst on HDD ?

give me details on how many hdd's have u got , linux is on which hdd's which partition and same for windows windows (which version by the way )


in the mean time have a look here

http://diddy.boot-la...es/boot.htm#mbr

http://diddy.boot-la...s/multiboot.htm

and here

http://diddy.boot-la...es/boot.htm#pbs

plz remember , that from which device grub4dos boots it sets it as hd0 means it sets that device as root.

so in ur case ur attached hdd becomes hd1 , and ur usb becomes HD0 if u ll boot from it .

im still not sure why the above entry lead u back in ur usb . but anyhow can u give me output of the following plz

title boot primary hdd

map (hd1) (hd0)

map (hd0) (hd1)

map --hook

root (hd1,0)

chainloader +1

best 'd be to use command line when experimenting .

#11 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 03:32 PM

--------HD1-------------------------------------HD2--------------------------------USB
---------*-------------------------------------------*------------------------------------*
ubuntu+space-----------------------------------seven--------------------------multiboot
3 partitions-------------------------------------1 partition----------------------1 partition
---- | ------------------------------------------------- |--------------------------------- |
1 swap--------------------------------------------1 ntfs --------------------------1 fat32
1 ext2(or3?)
1 ntfs


BOOT : GRUB on HD1
CHOICE: ubuntu & seven

USB : grub4dos with message (gfx)



title boot primary hdd

map (hd1) (hd0)				   

map (hd0) (hd1)

map --hook

root (hd1,0)

chainloader +1
---> Filesystem type is fat, partition type 0x0C

#12 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 03:50 PM

map (hd1) (hd0)


->back to line

map (hd0) (hd1)

->back to line

map --hook

->back to line

root (hd1,0)

->Filesystem type is fat, partition type 0x0C

chainloader +1

->back to line

#13 maanu

maanu

    Gold Member

  • Advanced user
  • 1134 posts
  •  
    Pakistan

Posted 25 August 2009 - 03:57 PM

the report seems like a puzzle :)

plz give me the following details

boot from usb , go to cmd and write
geometry (hd0)

ENTER

plzz post exect details .

then
geometry (hd1)

ENTER

plzz post exect details ,

also at cmd line , issue a cmd ,

find /menu.lst

what u see , post it plz

and
find /grldr

repeat the last two commands , By booting from ur hdd , (UNPLUG ur usb before it )

#14 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 04:11 PM

geometry (hd0)

->drive 0x80(LBA) : C/H/S=925/255/63, Sector Count/Size=14860125/512
Partition num : 0, active, Filesystem type is fat, partition type 0x0C

geometry (hd1)

->drive 0x81(LBA) : C/H/S=1024/255/63, Sector COunt/SIze=16450560/512
Partition num: 0, active, Filesystem type is ext2fs, partition type 0x83
Partition num: 1, active, Filesystem type is ntfs, partition type 0x07
Partition num: 2, active, Filesystem type unknown, partition type 0x82
Partition num: 3, active, Filesystem type is ext2fs, partition type 0x83

*lol ? I think i don't remember the 4 partition..*

find /menu.lst

->(hd0,0)

find /grldr

->(hd0,0)
(hd2,0)

*wait a minute for hdd reply* ( repeat the last two commands , By booting from ur hdd , (UNPLUG ur usb before it ) )

#15 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 04:19 PM

find /menu.lst   &   find /grldr
->file not found (I'm on the grub of my harddrive...with unplug usb)

#16 maanu

maanu

    Gold Member

  • Advanced user
  • 1134 posts
  •  
    Pakistan

Posted 25 August 2009 - 04:48 PM

1. when u boot ONLY from ur hdd . what menu u got ?
2. are u BY ANY CHANCE using a cracked windows 7 ?


i need some more details ,

from cmdline ofcource

find --set-root --ignore-floppies --ignore-cd /bootmgr

map () (hd0)

map (hd0) ()

map --rehook

find --set-root --ignore-floppies --ignore-cd /bootmgr

chainloader /bootmgr

savedefault --wait=2

boot

root (hd1,0)

chainloader +1

boot

take it to 4 same as above , means root (hd1,0) (hd1,1 ) and so on .


one of ur partitions reported unknown fs , can u access all of ur partitions from ur linux or 7 OS ?

#17 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 05:07 PM

BOOT only on my hdd :

Posted Image

here you can see "windows xp" but it is windows seven.. just the wrong name (before i've got xp)

I'm using the tiiiiiiiiiiiiiiiiit windows seven.. ^^ (why you ask me this ?)


----------------------------------------

excuse me but this :
find --set-root --ignore-floppies --ignore-cd /bootmgr

map () (hd0)

map (hd0) ()

map --rehook

find --set-root --ignore-floppies --ignore-cd /bootmgr

chainloader /bootmgr

savedefault --wait=2

boot

where i write this ? menu.lst ? or "c" command on usb ?

(one of ur partitions reported unknown fs , can u access all of ur partitions from ur linux or 7 OS ?)
->maybe it's a 1-10mb size.. it's not important, aren't you ?

#18 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 05:17 PM

(one of ur partitions reported unknown fs , can u access all of ur partitions from ur linux or 7 OS ?)
->maybe it's a 1-10mb size.. it's not important, aren't you ?


OR IT IS THE SWAP I THINK

#19 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7101 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 25 August 2009 - 07:44 PM

It seems to me like there is a misunderstanding. :)

You boot from USB, then the USB device is (hd0) and the internal hard disk is (hd1).

This:
title boot primary hdd

map (hd1) (hd0)				   

map (hd0) (hd1)

map --hook

root (hd1,0)

chainloader +1

explained:
title boot primary hdd <-just some text you will see

map &#40;hd1&#41; &#40;hd0&#41;		<-map hd1 to hd0		 

map &#40;hd0&#41; &#40;hd1&#41;		<-map hd0 to hd1

map --hook			 <- hook the above mapping, now the drives are exchanged, thus the USB device is hd1 and the internal hard disk is hd0

root &#40;hd1,0&#41;		   <- set ROOT on the USB device&#39;s first partition

chainloader +1		 <- boot the bootsector of the USB device

maybe what you want to do is:

title boot primary hdd
map (hd1) (hd0)
map (hd0) (hd1)
map --hook
root (hd0,0)
chainloader +1


i.e.:
title boot primary hdd <-just some text you will see

map &#40;hd1&#41; &#40;hd0&#41;		<-map hd1 to hd0		 

map &#40;hd0&#41; &#40;hd1&#41;		<-map hd0 to hd1

map --hook			 <- hook the above mapping, now the drives are exchanged, thus the USB device is hd1 and the internal hard disk is hd0

root &#40;hd0,0&#41;		   <- set ROOT on the internal hard disk device&#39;s first partition AND fake it was the &#34;boot&#34; device.

chainloader +1		 <- boot the bootsector of the internal hard disk device&#39;s first partition

However this is WRONG:

->drive 0x81(LBA) : C/H/S=1024/255/63, Sector COunt/SIze=16450560/512
Partition num: 0, active, Filesystem type is ext2fs, partition type 0x83
Partition num: 1, active, Filesystem type is ntfs, partition type 0x07
Partition num: 2, active, Filesystem type unknown, partition type 0x82
Partition num: 3, active, Filesystem type is ext2fs, partition type 0x83


Only ONE partition can (and should) be ACTIVE.

:)

jaclaz

#20 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 07:58 PM

Only ONE partition can (and should) be ACTIVE.

Oh yes sorry, an error i make... bad copying..

#21 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 08:17 PM

THANKS A LOT !


title boot primary hdd

map &#40;hd1&#41; &#40;hd0&#41;

map &#40;hd0&#41; &#40;hd1&#41;

map --hook

root &#40;hd0,0&#41;

chainloader +1

WORK !

But an error : :)

error 15 : file not found

you can see my usb key search the mbr or grldr..but why my hard drive don't do that ?

#22 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7101 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 25 August 2009 - 08:40 PM

Do the above manually, in Command line, one line at the time, pressing enter after each one.

when you get after
root &#40;hd0,0&#41;
[ENTER]

type:

chainloader /

and press the [TAB] key, you should see a listing of the root of your internal hard disk.

Which loader do you have on your internal hard disk?

"legacy" GRUB?
If yes it is very possible that the error 15 comes from it (and not from the grub4dos on the USB stick).

If this is the case, you can "continue" booting from the grub4dos, i.e. instead of "chainloader" type:
configfile /
[TAB]
continue TAB autocompletion until you find your menu.lst file on the hard disk, typically
configfile /boot/grub/menu.lst
press [ENTER]

jaclaz

#23 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 08:56 PM

chainloader / &#34;+ tab&#34;

-> Possibles files are : lost+found var home media etc cdrom bin boot dev initrd lib mnt opt proc root sbin srv tmp usr initrd.img vmlinuz initrd.img.old vmlinuz.old

configfile /boot/grub/menu.lst

->back to the grub


"legacy" GRUB?
If yes it is very possible that the error 15 comes from it (and not from the grub4dos on the USB stick).


legacy = old ? true ?

#24 cartman29

cartman29

    Member

  • Members
  • 32 posts
  •  
    France

Posted 25 August 2009 - 09:10 PM

Which loader do you have on your internal hard disk?


Do you have a command to view it ?

#25 was_jaclaz

was_jaclaz

    Finder

  • Advanced user
  • 7101 posts
  • Location:Gone in the mist
  •  
    Italy

Posted 25 August 2009 - 09:16 PM

->back to the grub

....

legacy = old ? true ?


There is some misunderstandings, possibly language barrier. :)

Does a menu.lst exist on your hard disk?

Does it exist in /boot/grub/menu.lst? OR you just typed the example INSTEAD of using TAB to navigate to it?

i.e. what you should do:
configfile /
[TAB]
configfile /b
[TAB]
configfile /boot/
[TAB]
etc., etc. until you find the menu.lst file on your hard disk.

Yes, "legacy" means "old" (but also "stable" and "tested" :))
Anyway, the GRUB currently used in Linux Operating Systems is usually grub 0.97 also named "legacy GRUB" to distinguish it from GRUB 2.0 (which is still in development).
Grub4dos is more "fresh" or "new" than GRUB 0.97, and has a number of features that GRUB 0.97 simply misses.

jaclaz




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users