LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   Can't boot from hardisk (https://www.linuxquestions.org/questions/slackware-14/cant-boot-from-hardisk-80032/)

thundersnows 08-07-2003 10:36 PM

Can't boot from hardisk
 
Hi,
I've installed Slackware 2.4.18 and worked smoothly. Right now everytime I run my computer, I boot from floppy disk.
I want to change to boot directly from my hardisk. How to do that ?
I've tried to install lilo from Slackware CD. When I tried to boot from hd, I can see Linux logo, and loading configuration.
The problem is I got message :
VFS : Insert root floppy and press ENTER
If I just press enter it show :
VFS : cannot open root device "202" or 02:02
Please append a correct "root=" boot option
Kernel panic : VFS : unable to mount root fs on 02:02

In my lilo.conf :
image=/boot/vmlinuz
root=/dev/hda1
label = Linux
read-only

My hardisk have 2 partition, 1 for linux and the other one for swap.
What should I change ?
Thanks

320mb 08-08-2003 03:01 AM

the proper mount command is..........
mount root=/dev/hda1 ro
partition "HAS" to be mounted as "read only" first!! then the system will initialize full access.....IE read/write

Cerbere 08-08-2003 03:29 AM

I don't think the mount command has much to do with your problem, because if lilo were functioning correctly you wouldn't be prompted for it. What you have posted from your lilo.conf looks correct, could you post the complete lilo.conf? The problem may be earlier in the file. While you're at it, could you also post your fstab to check if you are mounting your root partition correctly and (just for s#|+s and giggles) the output of fdisk -l to check that your root partition is /dev/hda1. You should also check that you have a suitable kernel in /boot/vmlinuz. And I assume that you remembered to run /sbin/lilo after you edited your lilo.conf, and you did take out your boot floppy :-)

Enjoy!
--- Cerbere

thundersnows 08-08-2003 10:00 PM

here's my fstab :
/dev/hda2 swap swap defaults 0 0
/dev/hda1 / ext2 defaults 1 1
/dev/cdrom /mnt/cdrom iso9660 noauto,users,ro 0 0
/dev/fd0 /mnt/floppy auto noauto,users 0 0
none /dev/pts devpts gid=5,mode=620 0 0
none /proc proc defaults 0 0

my lilo.conf :
boot = /dev/hda
message = /boot/boot_message.txt
prompt
timeout = 1200
change_rules
reset
vga = 771
image = /boot/vmlinuz
root = /dev/hda1
label = linux
read-only

And fdisk -l :
Disk /dev/hda : 255 heads, 63 sectors, 1216 cylinders
Units = cylinders of 16065 * 512 bytes

Device boot start end blocks id system
/dev/hda1 * 1 1020 8193179+ 83 linux
/dev/hda2 1021 1216 1574370 82 swap

do i just type /sbin/lilo ? i never run that. i'll try it.
thanks.

Cerbere 08-09-2003 01:17 AM

Yeah, any time you make a change to lilo.conf, you must run /sbin/lilo (as root) for the changes to take effect.

I don't think you need the 'change-rules' and 'reset' options in your lilo.conf. The rest looks good. But since you only have one OS (Linux), you might as well take out or comment out the 'prompt' and 'timeout' lines, or at least shorten the timeout period. You'll want to put those back in when you're trying out a new kernel, in which case you'll add another entry for the new kernel. Just a suggestion.

Enjoy!
--- Cerbere

thundersnows 08-11-2003 09:19 PM

yes, it's worked now. thanks for you help


All times are GMT -5. The time now is 11:54 PM.