Results 1 to 10 of 14
Hello,
So I am stuck in the bootloader hell. With a vintage PC
Ok, so here's the setup:
There is one HDD, with two primary partitions: 1st for the system, ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 04-16-2010 #1Just Joined!
- Join Date
- Apr 2010
- Posts
- 28
[SOLVED] Manual GRUB install for screwed up Luit Linux install
Hello,
So I am stuck in the bootloader hell. With a vintage PC
Ok, so here's the setup:
There is one HDD, with two primary partitions: 1st for the system, 2nd for the swap. I booted Luit Linux Live CD, and ran it's HDD install script. The Luit Linux is based on Damn Small Linux that uses kernel version 2.4.22. For some reason, it's bootloader LILO install did something wrong and the fresh install wouldn't boot: at boot does this:
By the way, I don't understand why the bootloader texts refer to GRUB, while the install script definitely was installing LILO.Code:GRUB Loading stage1.5. GRUB loading, please wait... Error 15
I can now boot again with that same Live CD (or any other CD that would boot to Linux), and once loaded, mount the hard disk and check and update it's contents. I'd like to install there as up-to-date GRUB version what that ancient hardware (48MB RAM) can take, and then configure the GRUB to load that install that's sitting on the hdd.
I will be very grateful for any advice. Unfortunately my knowledge of things like GRUB is very poor, so it's difficult to look up advice by searching the internet.
- 04-16-2010 #2forum.guy
- Join Date
- May 2004
- Location
- arch linux
- Posts
- 18,733
LILO sometimes has trouble overwriting GRUB if it still resides on the MBR.
You can clear the master boot record only, leaving partition tables alone by going to a terminal and running the following command:
You can run the above command using a liveCD if need be. If you use sudo, put sudo in front of the command. Don't forget that you'll need to run the lilo command before rebooting, and you can read more about LILO options that are available by running man lilo from the terminal.Code:dd if=/dev/zero of=/dev/sda bs=446 count=1
Edit: I just reread your post and might be confused. Are you wanting to keep GRUB, or install LILO?Last edited by oz; 04-16-2010 at 08:49 PM.
oz
- 04-16-2010 #3Just Joined!
- Join Date
- Apr 2010
- Posts
- 28
Yes, I'd like to install GRUB instead, I like it's configuration better, and also functionality. There is no GRUB install included in the Luit Linux distribution, but I hope that does not mean that it is not possible to use GRUB to load Luit Linux. From what I understand, all what GRUB cares about is that it can access it's stage files and the menu config file. So, if I'd manage to install it properly (ie, load the MBR with the right stuff, and let the GRUB install create the stage files in the right place, and then write correct config file) then that would be wonderful.
Regarding your reply, how would cleaning the MBR solve the problem in any context?
- 04-16-2010 #4forum.guy
- Join Date
- May 2004
- Location
- arch linux
- Posts
- 18,733
If Luit is based on DSL, you can probably use the DSL Wiki page to easily install GRUB:
Installing Grub - DSL Wiki
I thought you were trying to install LILO to the MBR, but sometimes LILO and GRUB can conflict, so I was thinking that having no bootloader residing on the MBR would make things easier. Hopefully, the GRUB HowTo above will help you to get GRUB installed and you'll be up and running. It's been years since I last ran DSL and I've never heard of Luit until you posted about it, so I'm just guessing the HowTo might work with Luit. If it doesn't, you should be able to install GRUB from source if there isn't a GRUB package for Luit and a package tool for installing it.oz
- 04-17-2010 #5Just Joined!
- Join Date
- Apr 2010
- Posts
- 28
Ok, so I used the tutorial (www:damnsmalllinux:org/wiki/index.php/Installing_Grub)
The site from where this tutorial suggests to download GRUB floppy/CD image, is dead, so I had to choose another option - Super GRUB Disk. I hope that's correct alternative to what is supposed to be used in that tutorial.
Now, when I boot the Super GRUB disk (based on GNU GRUB version 1.97.2), I really see no place where those GRUB commands that the tutorial teaches could be entered: I am presented with a menu, then I can type Ctrl+e to get to manual command entry mode, or Ctrl+c to get to the command line (prompt is sh:grub>). At no place I could enter something like
and boot. So from what I understand, the tutorial uses other type of GRUB.Code:title Luit Linux root (hd0,0) kernel /boot/vmlinuz-2.4.22-xfs makeactive boot
I tried to search up anything that tells what commands are for sh:grub prompt, but there seems to be very poor information on this.
The best thing I could master, was this:
... and then my PC rebooted. Perhaps I'm entering bad commands or bad parameters, I have no idea.Code:sh:grub> linux (hd0,1)/boot/vmlinuz-2.4.22-xfs root=/dev/hda1 [Linux-bzImage, setup=0x1400, size=0xdf9e4] sh:grub> boot Uncompressing linux... <some quick message that I coulnd't read>
Well, either I need to get another bootable GRUB (any suggestions?), with a version that has better online reference, or someone should teach me how to boot with this sh:grub what I have. Once I will get that existing linux to boot, only then I can start looking for ways how to actually install it from there. That is, unless there is some way how to boot with LiveCD and then do some witchcraft in order to install GRUB to the HDD.
- 04-17-2010 #6forum.guy
- Join Date
- May 2004
- Location
- arch linux
- Posts
- 18,733
I'm assuming that you are installing the older version of GRUB, now known as GRUB Legacy, and not the newer GRUB2. With either of them, keep in mind that you first install the GRUB package to your system, then you'll install GRUB to the MBR.
The GRUB (Legacy) Manual has step by step instructions with a couple of methods for installing it to the MBR:
GNU GRUB Manual 0.97
The best tutorial that I've found for working with GRUB is this one:
GRUB bootloader - Full tutorial
They have a link there for the GRUB2 Tutorial if you want to use that version, but I'd recommend sticking with the older GRUB for now.
The SuperGRUB disk that you mentioned should also be able to install GRUB, but you have to be careful there because they have both, GRUB Legacy and GRUB2 downloads available. SuperGRUB Disk downloads constructed from Legacy can be found here:
Index of /Super_Grub_Disk/download/binaries/sgdoz
- 04-17-2010 #7
Could you post the partition structure of your Hard disk and contents of /boot/grub/grub.conf file here?
Boot up from LiveCD of any Linux distro and execute fdisk -l command in Terminal.
Post output here.Code:su - /sbin/fdisk -l
* Its small L in fdisk -l.
You have to mount / partition in LiveCD to copy contents of its /boot/grub/grub.conf file.It is amazing what you can accomplish if you do not care who gets the credit.
New Users: Read This First
- 04-17-2010 #8Linux User
- Join Date
- Dec 2007
- Location
- Idaho USA
- Posts
- 358
That version is grub2. grub legacy should be version .97, If I'm to wrong.Now, when I boot the Super GRUB disk (based on GNU GRUB version 1.97.2)
- 04-18-2010 #9Just Joined!
- Join Date
- Apr 2010
- Posts
- 28
Oh, wow, three replies! This gives me hope I will be able to fix that poor gear for my kids.
Ozar:
I haven't got to that point yet. I have boot-broken HDD install, but I can boot Luit Linux LiveCD and do whatever is needed. But I don't feel safe (perhaps superstition) with that setup - when the active OS is in fact loaded in ramdrive, but I need to install the bootloader on the HDD, what the LiveCD-booted OS doesn't use at all. This is why I hoped to boot with some GRUB CD boot disk and then make manual configuration to boot the install that's there on HDD.I'm assuming that you are installing the older version of GRUB, now known as GRUB Legacy, and not the newer GRUB2. With either of them, keep in mind that you first install the GRUB package to your system, then you'll install GRUB to the MBR.
Ok, so I set forth and burned another Super Grub Disc, this time it's based on GNU GRUB version 0.97-os.1 it's syntanx really matches the one used in the tutorial that I referred to above.
So, I entered the commands:And, it got much futher than the previous time. Lot's of messages scrolling bye, but the last ones are errors:Code:root (hd0,0) kernel /boot/vmlinuz-2.4.22-xfs makeactive boot
It's interesting how it refers to hda6, while I have one just hard disk with two simple primary partitions: one for system, other for swap.Code:hda6: bad access: block=2, count=2 end_request: I/O error, dev 03:06 (hda), sector 2 EXT2-fs: unable to read superblock hda6: bad access: block=0, count=1 end_request: I/O error, dev 03:06 (hda), sector 0 FAT: unable to read boot sector hda6: bad access: block=64, count=2 end_request: I/O error, dev 03:06 (hda), sector 64 isofs_read_super: bread failed, dev=03:06, iso_blknum=16, block=32 Kernel panic: VFS: Unable to mount root fs on 03:06
So I am stuck with this particular plan for now, until I am pointed to the right direction.
devils casper:
Here's my partition structure:Could you post the partition structure of your Hard disk and contents of /boot/grub/grub.conf file here?
Regarding the grub.conf file, there is none. Originally the Luit Linux comes with LILO, and, at least for my hardware, the LILO install script fails. But, for the reference, here is the list of files in /boot:Code:Device Boot Start End Blocks Id System /dev/hda1 * 1 477 1923232+ 83 Linux /dev/hda2 478 525 193536 82 Linux swap
I don't know, perhaps I really should swipe the MBR clean... And then try to install the GRUB on HDD from within LiveCD, if this manual GRUB setup at boot-time proves to be sooo hard.Code:System.map [symbolic link to the file below] System.map-2.4.22-xfs boot.0300 config-2.4.22-xfs vmlinuz [symbolic link to the file below] vmlinuz-2.4.22-xfs
- 04-18-2010 #10
Create /boot/grub/grub.conf file manually.
Save file and reboot machine. GRUB Menu should appear at startup and Linux will boot up fine.Code:default=0 timeout=10 title Linux root (hd0,0) kernel /boot/vmlinuz root=/dev/hda1 ro
It is amazing what you can accomplish if you do not care who gets the credit.
New Users: Read This First




