LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices

Reply
 
Search this Thread
Old 12-13-2011, 08:11 PM   #76
hurry_hui
Member
 
Registered: Oct 2008
Location: Near Jakarta
Distribution: Slackware, Arch, Slax, Porteus, Tiny Core, Slitaz
Posts: 355
Blog Entries: 1

Rep: Reputation: 51

Quote:
Originally Posted by sdfi View Post
soo.. how do i get to this menu? ..all i have is a grub recovery prompt.
Since you can access fd0 let's start from this. Type line by line followed by ENTER. Pay attention to output, if there is error do not continue.

checking partition in floppy
Code:
ls (fd0)

let's assume there is part 1 in floppy and then try to load configfile to show menu. configfile requires configfile.mod hence setting prefix is needed.
Code:
set prefix=(fd0,1)/boot/grub/i386-pc
configfile (fd0,1)/boot/grub/grub.cfg

try to boot Debian 6.0
Code:
set prefix=(fd0,1)/boot/grub/i386-pc
set root=(hd0,5)
insmod (fd0,1)/boot/grub/i386-pc/part_msdos.mod
insmod (fd0,1)/boot/grub/i386-pc/ext2.mod
insmod (fd0,1)/boot/grub/i386-pc/linux.mod
linux /boot/vmlinuz-2.6.32-5-686 root=/dev/sda5 ro
initrd /boot/initrd.img-2.6.32-5-686
boot
to make it easy typing, type one or two characters followed by TAB.

HTH
 
Old 12-13-2011, 09:19 PM   #77
sdfi
Member
 
Registered: Oct 2011
Distribution: debian
Posts: 107

Original Poster
Rep: Reputation: Disabled
'ls (fd0)' returns 'error: bad filename'. 'ls (fd0,1)'/'ls (fd0,0)' returns 'error:no such partition'.
However, 'ls /' shows the contents of the floppy? (/boot and boot.catalog)

e: continued using the /boot/grub... path and 'configfile /boot/grub/grub.cfg' returns "Unknown command 'conifigfile'"

e2: if i set root=(hd0,5) at that point then i cannot (i don't know how if there is a way?) access the floppy drive again. If i set the root like that then (fd0,0/1) doesn't access it. Nor / of course. I tried using insmod before changing root but i was unable to load linux.mod; 'error: out of disk'

e3: a-ha.. so loading the other 2 modules.. then an ls shows the partitions are (then?) named like (hd0,msdos5) or (fd0,msdos1). and i can actually see the contents of the hdd for the first time with this... so if i 1) load part_msdos and ext2, then set the root to hd0,msdos5.. then try and load (fd0,msdos1)/.../linux.mod.. i get 'error: unknown filesystem' (ie on the floppy)?... update; it seems? that it wants it in the format (fd0)/.../linux.mod, however, then i still get 'out of disk'.

Last edited by sdfi; 12-13-2011 at 10:05 PM.
 
Old 12-13-2011, 10:15 PM   #78
hurry_hui
Member
 
Registered: Oct 2008
Location: Near Jakarta
Distribution: Slackware, Arch, Slax, Porteus, Tiny Core, Slitaz
Posts: 355
Blog Entries: 1

Rep: Reputation: 51
Quote:
Originally Posted by sdfi View Post
'ls (fd0)' returns 'error: bad filename'. 'ls (fd0,1)'/'ls (fd0,0)' returns 'error:no such partition'.
However, 'ls /' shows the contents of the floppy? (/boot and boot.catalog)

e: continued using the /boot/grub... path and 'configfile /boot/grub/grub.cfg' returns "Unknown command 'conifigfile'"

e2: if i set root=(hd0,5) at that point then i cannot (i don't know how if there is a way?) access the floppy drive again. If i set the root like that then (fd0,0/1) doesn't access it. Nor / of course. I tried using insmod before changing root but i was unable to load linux.mod; 'error: out of disk'

e3: a-ha.. so loading the other 2 modules.. then an ls shows the partitions are (then?) named like (hd0,msdos5) or (fd0,msdos1). and i can actually see the contents of the hdd for the first time with this... so if i 1) load part_msdos and ext2, then set the root to hd0,msdos5.. then try and load (fd0,msdos1)/.../linux.mod.. i get 'error: unknown filesystem' (ie on the floppy)?... update; it seems? that it wants it in the format (fd0)/.../linux.mod, however, then i still get 'out of disk'.
You know how it works now, however you did it backwards. set prefix, set root, insmod, etc. (fd0) is drive not partition. (When you cannot go or find some error with 'ls' just use set prefix=/boot/grub/i386-pc to go back to default.)

to access modules within the floppy you can

set prefix=/boot/grub/i386-pc --> use this before typing anything

or

set prefix=(fd0,1)/boot/grub/i386-pc --> it seems only available after you insmod-ing part_msdos

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

after you can 'ls (hd0,5)' or 'ls (hd0,msdos5)' you no longer need (fd0,1), instead try following:

insmod /boot/grub/i386-pc/part_msdos.mod --> this is perhaps already loaded
insmod /boot/grub/i386-pc/ext2.mod --> this is perhaps already loaded
insmod /boot/grub/i386-pc/linux.mod --> this is needed to load linux/kernel
linux /boot/vmlinuz-2.6.32-5-686 root=/dev/sda5 ro
initrd /boot/initrd.img-2.6.32-5-686
boot

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

or

just type
insmod /boot/grub/i386-pc/configfile.mod --> here we need to load configfle.mod
configfile /boot/grub/grub.cfg

HTH
 
Old 12-13-2011, 10:45 PM   #79
sdfi
Member
 
Registered: Oct 2011
Distribution: debian
Posts: 107

Original Poster
Rep: Reputation: Disabled
I was doing it in different order because it wasn't working.. and it definately only works with (fd0).. 'ls (fd0,1)/'/'ls (fd0,msdos1)/' gives 'unknown filesystem', but 'ls (fd0)/' shows contents. Anyway, i don't think it can find /i386-pc in /boot/grub/ (atleast not /i386-pc/linux.mod) on hd0,5. I have too many contents to see them all with 'ls (hd0,msdos5)/boot/grub/'.. is there any way to show only part of the ouput/result in this enviroment??

Last edited by sdfi; 12-13-2011 at 10:50 PM.
 
Old 12-13-2011, 11:04 PM   #80
hurry_hui
Member
 
Registered: Oct 2008
Location: Near Jakarta
Distribution: Slackware, Arch, Slax, Porteus, Tiny Core, Slitaz
Posts: 355
Blog Entries: 1

Rep: Reputation: 51
Quote:
Originally Posted by sdfi View Post
I was doing it in different order because it wasn't working.. and it definately only works with (fd0).. 'ls (fd0,1)/'/'ls (fd0,msdos1)/' gives 'unknown filesystem', but 'ls (fd0)/' shows contents. Anyway, i don't think it can find /i386-pc in /boot/grub/ (atleast not /i386-pc/linux.mod) on hd0,5. I have too many contents to see them all with 'ls (hd0,msdos5)/boot/grub/'.. is there any way to show only part in this enviroment??

I see after you ls you got /boot and boot.catalog.

You are now in floppy we should not go further to hd0,5 (if you insist to go to, grub files are available in /boot/grub/). I found something missing in that directory, so please stay in floppy. Here you will find /boot/grub/i386-pc

try again this line

Code:
insmod /boot/grub/i386-pc/configfile.mod
configfile /boot/grub/grub.cfg
I am sorry I cannot write clearly. English is not my tongue.

HTH
 
Old 12-13-2011, 11:39 PM   #81
widget
Senior Member
 
Registered: Oct 2008
Location: S.E. Montana
Distribution: Debian Testing, Stable, Sid and Manjaro, Mageia 3, LMDE
Posts: 2,248

Rep: Reputation: 371Reputation: 371Reputation: 371Reputation: 371
Quote:
Originally Posted by hurry_hui View Post
I see after you ls you got /boot and boot.catalog.

You are now in floppy we should not go further to hd0,5 (if you insist to go to, grub files are available in /boot/grub/). I found something missing in that directory, so please stay in floppy. Here you will find /boot/grub/i386-pc

try again this line

Code:
insmod /boot/grub/i386-pc/configfile.mod
configfile /boot/grub/grub.cfg
I am sorry I cannot write clearly. English is not my tongue.

HTH
While I am not sure what language you do speak, I know your English is a lot better than I would be in yours. You certainly are getting your point across well enough that progress is being made.

I think I am even learning somethings.

Keep up the good work.
 
Old 12-13-2011, 11:41 PM   #82
shravankumar
LQ Newbie
 
Registered: Sep 2011
Posts: 8

Rep: Reputation: Disabled
What is the LDAP?
Which Directory it is Accessing?
Why it is used?

---------- Post added 12-14-11 at 12:41 AM ----------

What is the diffrence between FTP &VSFTP
 
Old 12-14-2011, 09:35 AM   #83
colorpurple21859
Senior Member
 
Registered: Jan 2008
Location: florida
Distribution: slackware64-current, puppy, ubuntu
Posts: 1,348

Rep: Reputation: 184Reputation: 184
Are you now getting a grub recovery prompt when booting from the hard drive? If so try this:
I don't think it will work, but might be worth a try, you never know.

Quote:
insmod ext2
set root=(hd0,5)
kernel /boot/grub/core.img
boot
 
Old 12-14-2011, 01:13 PM   #84
sdfi
Member
 
Registered: Oct 2011
Distribution: debian
Posts: 107

Original Poster
Rep: Reputation: Disabled
'insmod /boot/grub/i386-pc/configfile.mod' = 'error: out of disk'

@purple; no command 'kernel'.

Last edited by sdfi; 12-14-2011 at 01:17 PM.
 
Old 12-14-2011, 01:28 PM   #85
colorpurple21859
Senior Member
 
Registered: Jan 2008
Location: florida
Distribution: slackware64-current, puppy, ubuntu
Posts: 1,348

Rep: Reputation: 184Reputation: 184
edit that, change kernel to linux and then try it,
linux /boot/grub/core.img
 
Old 12-14-2011, 03:36 PM   #86
sdfi
Member
 
Registered: Oct 2011
Distribution: debian
Posts: 107

Original Poster
Rep: Reputation: Disabled
again. no command linux. trying to load linux.mod -> 'out of disk'.
 
Old 12-14-2011, 08:16 PM   #87
hurry_hui
Member
 
Registered: Oct 2008
Location: Near Jakarta
Distribution: Slackware, Arch, Slax, Porteus, Tiny Core, Slitaz
Posts: 355
Blog Entries: 1

Rep: Reputation: 51
@widget:
Many thanks for your support. Btw, I am Indonesian.


@OP:
Let's do this differently.

The way grub2 works is every command needs certain module. To access each modules, grub2 needs to find path to the modules. In our case, (I am assuming) it is '(fd0)/boot/grub/i386-pc/'. To see what grub2 sees we need to run 'set' command.

Pay attention to this. After typing each command, sometimes grub2 changes its settings; hence you cannot continue typing certain line.

Before we move on, check what is the output of 'set' and 'ls' and write them down. If 'set' generates '(fd0)/boot/grub/i386-pc/' (or as resulted from first 'set' command) and 'ls' generates '/boot boot.catalog', we can continue typing.

In a case where such output is different then we need to reset 'set prefix=(fd0)/boot/grub/i386-pc/' (or as resulted from first 'set' command). And recheck whether 'ls' generates '/boot boot.catalog' output.

If both results are matched, we can continue issuing command as previously posted.

HTH

PS:

To fix 'out of disk' message.

Code:
  insmod ata
  update_paths

Last edited by hurry_hui; 12-14-2011 at 08:23 PM. Reason: Rearrange sentences
 
Old 12-14-2011, 08:40 PM   #88
sdfi
Member
 
Registered: Oct 2011
Distribution: debian
Posts: 107

Original Poster
Rep: Reputation: Disabled
on boot;
Quote:
Originally Posted by set
prefix=(fd0)/boot/grub/i386-pc
root=fd0
'ls' = '(hd0) (fd0)'
'ls /' = './ ../ boot/ boot.catalog'


Here is what is happening... please ask if anything is not 100% clear


i load part_msdos and ext2 with insmod. Works. 'ls' (not 'ls /'!) shows (hd0,msdos1), (hd0,msdos5), (fd0) etc.

LOAD LINUX;
'insmod linux' (from floppy) = 'error: out of disk'

TRY FIX;
'insmod ata' = 'error: no device connected'.
Now 'ls' (not 'ls /'!) shows (ata0,msdos1), (at0, msdos5), (ata2) etc. Cannot access floppy by 'ls (ata2)/' ('error: ATAPI read error.' -- note external USB floppy drive) Same with '(ata2,msdos1)'.
'ls (fd0)/' or 'ls /' = 'error: no such disk'. Same with (fd0,msdos1). SO-- AFTER 'insmod ata' CANNOT ACCESS FLOPPY.

ALSO, 'update_paths' = "unknown command 'update_paths'"


TRY TO LOAD linux.mod from HDA5;
'insmod (ata0,msdos5)/boot/grub/i386-pc/linux.mod' (OR 'hd0' without 'insmod ata') = 'error: file not found

'ls (ata0,msdos5)/boot/grub/i386-pc' = 'error: file not found'
'ls (ata0,msdos5)/boot/grub' gives more items than fit on the screen. There is a 'linux.mod' file. If i run 'insmod (ata0,msdos5/boot/grub/linux.mod' = 'error: incompatible licence'.

Last edited by sdfi; 12-14-2011 at 09:19 PM.
 
Old 12-14-2011, 09:52 PM   #89
hurry_hui
Member
 
Registered: Oct 2008
Location: Near Jakarta
Distribution: Slackware, Arch, Slax, Porteus, Tiny Core, Slitaz
Posts: 355
Blog Entries: 1

Rep: Reputation: 51
Quote:
Originally Posted by sdfi View Post
on boot;

prefix=(fd0)/boot/grub/i386-pc
root=fd0
'ls' = '(hd0) (fd0)'
'ls /' = './ ../ boot/ boot.catalog'
From the output, this means we can start insmod-ing without setting prefix.

Lets's try to load configfile.
Code:
insmod configfile
configfile /boot/grub/grub.cfg
This (if runs properly) will bring you grub2 menu. You can then choose 'Detect any OS' menu.

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

Following quote added by OP while I am editing post and testing some commands. I added dashes for easy reading.

Quote:
Here is what is happening... please ask if anything is not 100% clear


i load part_msdos and ext2 with insmod. Works. 'ls' (not 'ls /'!) shows (hd0,msdos1), (hd0,msdos5), (fd0) etc.
-(1)------------

LOAD LINUX;
'insmod linux' (from floppy) = 'error: out of disk'
-(2)------------

TRY FIX;
'insmod ata' = 'error: no device connected'.
Now 'ls' (not 'ls /'!) shows (ata0,msdos1), (at0, msdos5), (ata2) etc. Cannot access floppy by 'ls (ata2)/' ('error: ATAPI read error.' -- note external USB floppy drive) Same with '(ata2,msdos1)'.
'ls (fd0)/' or 'ls /' = 'error: no such disk'. Same with (fd0,msdos1). SO-- AFTER 'insmod ata' CANNOT ACCESS FLOPPY.
-(3)------------

ALSO, 'update_paths' = "unknown command 'update_paths'"
-(3a)------------

TRY TO LOAD linux.mod from HDA5;
'insmod (ata0,msdos5)/boot/grub/i386-pc/linux.mod' (OR 'hd0' without 'insmod ata') = 'error: file not found
-(4)------------

'ls (ata0,msdos5)/boot/grub/i386-pc' = 'error: file not found'
'ls (ata0,msdos5)/boot/grub' gives more items than fit on the screen. There is a 'linux.mod' file. If i run 'insmod (ata0,msdos5/boot/grub/linux.mod' = 'error: incompatible licence'.
-(4a)-----------
(1) Works as expected.
(2) This is weird. Perhaps this because grub2 need full path to linux (i.e., (fd0)/boot/grub/i386-pc/)
(3) Insmod ata takes you to (ata2) (do everything with ata2). Every reference to (ata2) is similar to (fd0)/ (that is root of floppy). This time you can no longer access floppy, which is as intended. Type 'set' again to check path.
(3a) 'update_paths' is needed to reset path to new path--that is (ata2).
(4) This path does not exist. You have /boot/grub/ on hdd to access grub2 modules.
(4a) 'incompatible licence'--I am not sure; this might refer to different version of grub2.
 
Old 12-14-2011, 11:12 PM   #90
shravankumar
LQ Newbie
 
Registered: Sep 2011
Posts: 8

Rep: Reputation: Disabled
What is LDAP?
Which directory we are accessing through LDAP?
Why the LDAP used
 
  


Reply

Tags
grub, install, mbr


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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] cannot install grub (grub-probe says 'unknown fs' with ext4 and md raid) cusco Linux - Software 3 03-15-2011 01:58 AM
Grub - Does fedora automatically install a bootloader like grub? or... mitchell7man Linux - Software 10 05-09-2007 10:49 AM
Booting my new ubuntu install = "GRUB GRUB GRUB GRUB GRUB" etc. dissolved soul Ubuntu 2 01-13-2007 12:55 PM
Need to (re)install GRUB: fedora c4 rescue cd (and GRUB) unable to see the harddisk whencat Fedora 4 03-05-2006 02:01 PM
Grub 0.97 issues on slackware - grub-install is very slow, & updating menu.lst fails dieyouspammer Linux - Software 1 02-27-2006 01:06 PM


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

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration