View previous topic :: View next topic |
Author |
Message |
mahdi1234 Guru
Joined: 19 Feb 2005 Posts: 559 Location: Being There
|
Posted: Tue Dec 13, 2005 7:18 am Post subject: how to fix broken lilo? [SOLVED] |
|
|
hi,
i just resized some of my partitions - including fat32 with data and boot/root one on ext2. though after rebooting there's no lilo anymore and only 999999 appears.
I have booted into knoppix, did su, chroot /mnt/hdc7 and tried to run /sbin/lilo - but i got error
Code: |
knoppix@ttyp1[knoppix]$ su
root@ttyp1[knoppix]# chroot /mnt/hdc7
bash-2.05b# su
bash-2.05b# /sbin/lilo
Fatal: open /dev/hdc: Permission denied
|
am i doing something wrong (i have write rights on that partition)?
thx,
mahdi
Last edited by mahdi1234 on Tue Dec 13, 2005 6:30 pm; edited 1 time in total |
|
Back to top |
|
|
mahdi1234 Guru
Joined: 19 Feb 2005 Posts: 559 Location: Being There
|
Posted: Tue Dec 13, 2005 7:34 am Post subject: |
|
|
figured out one more thing ... i probaly need to mount boot as well for lilo to compare against conf, though this happens
Code: |
bash-2.05b# mount /boot
mount: block device /dev/hdc6 is write-protected, mounting read-only
mount: cannot mount block device /dev/hdc6 read-only
|
/dev/hdc6 is not mounted under knoppix at all. |
|
Back to top |
|
|
dwblas Guru
Joined: 14 Jul 2003 Posts: 525 Location: Southern California (No jokes please)
|
Posted: Tue Dec 13, 2005 8:52 am Post subject: |
|
|
First, check that hdc7 is actually mounted. Trying to mount hdc6 as boot won't work. First of all, Knoppix has it's own /boot partition that is different from yours, and second, it will not access your /etc/fstab so it doesn't know where to mount it. I don't think you need it, but don't really know, but you can mount your hdc6 (boot) somewhere and then see man lilo. I think you want the -C option to specifiy where your /etc/config file is actually located. |
|
Back to top |
|
|
mahdi1234 Guru
Joined: 19 Feb 2005 Posts: 559 Location: Being There
|
Posted: Tue Dec 13, 2005 9:29 am Post subject: |
|
|
I'm now off my linux comp so cannot try your suggestion - though I'm mounting boot folder when in chrooted environment i.e. under my gentoo system and it SHOULD recognize correctly my fstab - at least when I fired MC it did recognized all my customization.
Same applies to running /sbin/lilo - it is under chrooted environment, not the knoppix one. |
|
Back to top |
|
|
dwblas Guru
Joined: 14 Jul 2003 Posts: 525 Location: Southern California (No jokes please)
|
Posted: Tue Dec 13, 2005 3:46 pm Post subject: |
|
|
Yes that should work --But It Isn't--, so check everything. Do you have 3 disk drives in your computer, hda, hdb, & hdc?? If you still don't get it running, please post your /etc/fstab file. That could also be the problem. |
|
Back to top |
|
|
mahdi1234 Guru
Joined: 19 Feb 2005 Posts: 559 Location: Being There
|
Posted: Tue Dec 13, 2005 6:30 pm Post subject: |
|
|
thanks for suggestions ... at the end it worked this way
boot under knoppix and then
Code: |
$ su
$ mount -o dev /dev/hdc7/ mnt/hdc7
$ mount /dev/hdc6 /mnt/hdc6
$ chroot /mnt/hdc7
$ mount /dev/hdc6 /boot (or mount /dev/hdc6/ boot don't remember exactly)
$ /sbin/lilo
|
where hdc6 is boot and hdc7 root partition. now i have reference next time i messup my system ;). |
|
Back to top |
|
|
|