LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   incorrect LILO selection SLACK install - no boot from hda1 (https://www.linuxquestions.org/questions/linux-newbie-8/incorrect-lilo-selection-slack-install-no-boot-from-hda1-486462/)

studioq 09-24-2006 07:01 AM

incorrect LILO selection SLACK install - no boot from hda1
 
Hello...
During the Slack install process I was being walked through it over the phone by an experienced Slack user which really helped things move along.

The one thing we overlooked was the proper selection when it came time to install LILO.
I think I was given a choice as to whether or not to over write the MBR and my guide told me not to. I think he may have thought I was going to set up a dual boot device. I'm not. Slackware is the only OS.

Now the system needs a floppy at boot, which I'm not really comfortable with. I would like the system to boot normally like it should which leads me to this question:

I have read some methods for reinstalling and reconfiguring LILO in the Slack Book. All of it seems to make sense but it it one of those things I am not comfortable doing without some guidance. What I think I want to do is overwrite the MBR with LILO so it is the only resident boot loader on the system. People have said it can be done - but I really wouldn't know where or how to start.

Thanks,
Studioq

saikee 09-24-2006 07:40 AM

Boot up Slackware with the floppy
Click terminal mode, type "su", supply the password and become the super user witb the root privileage to amend the system file

The Lilo comman "lilo -b" allow you to put Lilo anywhere you wish to
Code:

lilo -b /dev/hda
put Lilo in the first IDE disk
Code:

lilo -b /dev/sda
put Lilo in the first Sata disk

Only you know which your book disk hda or sda boot first so choose the one that is at the top of the booting queue.

Code:

lilo -b /dev/fd0
puts Lilo in the floppy

Code:

lilo -b /dev/hda9
puts Lilo in the partition hda9 and so on

The last alternative is for the OS residing in hda9 to be booted by the boot loader controlling the MBR.

Lastly if you alter /etc/lilo.conf you must issue the "lilo" command in a terminal so that the bootloader is re-compiled, otherwise the changes will not be implemented.

studioq 09-24-2006 09:12 AM

The boot disk is an IDE. I followed the normal convention of formatting the drives hda1 - hda2 - hda3...
I haven't made any modifications to /etc/lilo.conf.. Will I have to make some changes after performing the above commands? Or does performing the above commands make alterations to the .conf file which in turn requires me to issue the lilo command at the end.. Just so I understand.. Thank you...

saikee 09-24-2006 12:16 PM

If you Lilo boots fine from the floppy then there is no need to change it. I just remind you of the characrteristic of Lilo.

Lilo, Grub and XP's NTLDR actually all keep the boot loader in the root partition of the hard disk. To boot it from the MBR a user must ask the boot loader to replicate its first 512 bytes there and burn the boot loader address into it too to form a link.

studioq 09-24-2006 12:27 PM

[QUOTE=saikee]If you Lilo boots fine from the floppy then there is no need to change it.[QUOTE]

In this case "it" would be the .conf file?
Dont change it and proceed with the above commands in order to get the system to boot correctly?

saikee 09-24-2006 12:45 PM

Yep.

If Lilo has a probelm to boot then you can only make it toe the line by amending /etc/lilo.conf. Right? After amendments you must issue "lilo" as a command in a Bash shell so that Lilo recompiles its boot loader.

If Lilo boots satisfactorily then its /etc/lilo.conf has no error and so you should leave it alone.

louieb 09-25-2006 09:58 PM

Thanks this thread fixed my problem. I installed slackware over a ubuntu install and used the same option as the origional post by studioq. But the mbr still had grub in it. and grub could not find stage1 so
Code:

lilo -b /dev/hda
replaced grub with lilo and now I don't need the floppy to boot.

studioq 09-26-2006 04:38 AM

I am glad this helped. I tried to make the title key word specific so that someone with the same issue could find it. I have yet to perform this operation.. Many fish to fry.. But I will report my results here..

studioq 09-26-2006 07:38 AM

It still didn't work. I am probably doing something wrong..
 
I tried to make the modifications to lilo by typing:
lilo -b /dev/hda
and got a response of "Ignoring entry 'boot' - Added Linux.

The system wont boot from disk...

When I type su nothing happens either. Should I be looged on as someone other than root when I ussue the 'su' command? Or could it be a problem that I never set an su password?
I only ask because I dont know..
Thank you..

saikee 09-26-2006 07:55 AM

Only a root user is allowed to touch the system files in Linux, so persevere with it.

When Lilo returns the message "added Linux" it means the compilation was successful and the distro was added without any error.

The above is Lilo's part in not finding any syntax error in the /ect/lilo.conf. The content inside has been found executable as Lilo check each entry during compilation. If one or two commands are rubbish then there is nothing Lilo can do as it just execute them one by one. No other boot loader bothers to check the correctness of the figuration entries, except Lilo.

If your system still refuses to boot can you paste the error message here? A complete printout of /etc/lilo.conf helps also.

Slackware is the easiest distro in the world to boot with only a standard kernal name as "vmlinuz" and no initrd file.

In fact if there is any distro that I have difficulty in booting 75% of them can be fired up by using Slackware's kernel.

studioq 09-26-2006 08:47 AM

The error I keep getting is:
Ignoring entry 'boot'
Added linux*

I have also gotten the error:
Warning! dev/hda is not set as active

and
Warning! dev.hda1 is not set as active

depending on if I tinkered with the number set in lilo.conf.

Also, when I login as root and type 'su' nothing happens.
Below is a copy of lilo.conf


# LILO configuration file
# generated by 'liloconfig'
#
# Start LILO global section
boot = /dev/hda
message = /boot/boot_message.txt
prompt
timeout = 1200
# Override dangerous defaults that rewrite the partition table:
change-rules
reset
# VESA framebuffer console @ 1024x768x256
vga = 773
# Normal VGA console
# vga = normal
# VESA framebuffer console @ 1024x768x64k
# vga=791
# VESA framebuffer console @ 1024x768x32k
# vga=790
# VESA framebuffer console @ 1024x768x256
# vga=773
# VESA framebuffer console @ 800x600x64k
# vga=788
# VESA framebuffer console @ 800x600x32k
# vga=787
# VESA framebuffer console @ 800x600x256
# vga=771
# VESA framebuffer console @ 640x480x64k
# vga=785
# VESA framebuffer console @ 640x480x32k
# vga=784
# VESA framebuffer console @ 640x480x256
# vga=769
# End LILO global section
# Linux bootable partition config begins
image = /boot/vmlinuz
root = /dev/hda1
label = Linux
read-only
# Linux bootable partition config ends
~
~
~

saikee 09-26-2006 02:29 PM

If you log in as root the command "su" should cause no response.

A lot of your so call problems isn't real.

Ignoring entry 'boot' = Lilo doesn't make much use of your "boot = /dev/hda" statement.

Linux doesn't use active flag in a partition and so any complaint is irrelevant.

I couldn't fault your lilo.conf as you haven't pasted the error during booting. I would try to put a "#", thus disabling that line, in front all the lines except
Code:

timeout = 1200
 vga = 773
 image = /boot/vmlinuz
 root = /dev/hda1
 label = Linux
 read-only

Lilo may get into trouble to load "boot_message.txt" if it cannot be found from /boot directory.

Paste the content of the screen after you issue a Bash command
Code:

fdisk -l
so that we get a confirmation of your partition scheme.

studioq 09-26-2006 05:56 PM

One other thing someone mentioned today is that there may be some system bios issue that is hanging it up. That is one thing I dont know about though. I am going to try to cause the error. I also dont know where I can find an error log for the boot process. If I can find that I will paste it too.... Here we go..

saikee 09-26-2006 06:30 PM

You probably have to write the error down if Slackware fails to boot. It should be just a couple of lines.

studioq 09-26-2006 06:46 PM

When the system finishes POST - I get no boot error. It just sits there. Normally It would tell me if it couldn't find a boot device. But this one just sites there.

After perfoming the above commands this is the text that was output:

root@filebox:/etc# lilo
Warning: RAID1 install implied by omitted 'boot='
Warning: Partition 1 on /dev/hda is not marked Active.
Added Linux *
root@filebox:/etc#

root@filebox:~# fdisk -1
fdisk: invalid option -- 1

Usage: fdisk [-b SSZ] [-u] DISK Change partition table
fdisk -l [-b SSZ] [-u] DISK List partition table(s)
fdisk -s PARTITION Give partition size(s) in blocks
fdisk -v Give fdisk version
Here DISK is something like /dev/hdb or /dev/sda
and PARTITION is something like /dev/hda7
-u: give Start and End in sector (instead of cylinder) units
-b 2048: (for certain MO disks) use 2048-byte sectors

After entering th "-l" parameter I got this:

root@filebox:~# fdisk -l

Disk /dev/hda: 61.4 GB, 61471162368 bytes
255 heads, 63 sectors/track, 7473 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/hda1 1 3000 24097468+ 83 Linux
/dev/hda2 3001 6000 24097500 83 Linux
/dev/hda3 6001 7473 11831872+ 82 Linux swap
root@filebox:~#


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