I have Mandriva 2009 installed on my main boot drive.
I have another drive that I wish to run LILO off of, since I will be
updating its kernel.
The problem is that that drive runs as part of a set-top box like
application, so it boots right up to the main application program w/o
the LILO prompt, and there's no way for me to boot up from it into a
shell and run LILO.
Is there any way I can update that drive using LILO, while booted up
from my Mandriva box? I've read about chroot but I'm not sure how to
use it, despite reading the man page.
> I have Mandriva 2009 installed on my main boot drive.
> I have another drive that I wish to run LILO off of, since I will be
> updating its kernel.
I don't understand from the above, whether you are going to be updating
the kernel on the first Mandriva drive, or on something installed on the
second drive.
What do you currently have installed on the second drive?
Why do you want to install lilo on the second drive?
Using rpmdrake, or urpmi, to install a new kernel will add new entries
to /etc/lilo.conf or /boot/grub/menu.1st, as appropriate. The old
kernel entries will still be available, until you urpme the old
kernels.
> The problem is that that drive runs as part of a set-top box like
> application, so it boots right up to the main application program w/o
> the LILO prompt, and there's no way for me to boot up from it into a
> shell and run LILO.
In /etc/lilo.conf, you can specify where lilo is to be installed.
For example, to install lilo in the beginning of the root filesystem,
you'd include a line like
boot=/dev/sda14
replacing /dev/sda14 with the appropriate device name for that partition.
To install it in the mbr of the first drive,
boot=/dev/sda or for the second drive, boot=/dev/sdb.
Regards, Dave Hodgins
--
Change nomail.afraid.org to ody.ca to reply by email.
(nomail.afraid.org has been set up specifically for
use in usenet. Feel free to use it yourself.)
> What do you currently have installed on the second drive?
It's an embedded "appliance" that has a custom Linux kernel 2.4, which
I wish to update to 2.6. So, after I update the kernel over to the, I
understand I will have to run LILO.
> Why do you want to install lilo on the second drive?
LILO is already there. I'm not installing it. It's already the
bootloader. The problem is I don't have a shell for this drive as it
boots up directly to the application.
> Using rpmdrake, or urpmi, to install a new kernel will add new entries
> to /etc/lilo.conf or /boot/grub/menu.1st, as appropriate. The old
> kernel entries will still be available, until you urpme the old
> kernels.
I know how to edit the lilo.conf, but my problem is physically running
the LILO. I need a shell to do that as a primary drive, and the drive
doesn't have it. Hence I'm wondering if there's a way to do this as a
2nd drive.
> > The problem is that that drive runs as part of a set-top box like
> > application, so it boots right up to the main application program w/o
> > the LILO prompt, and there's no way for me to boot up from it into a
> > shell and run LILO.
>
> In /etc/lilo.conf, you can specify where lilo is to be installed.
> For example, to install lilo in the beginning of the root filesystem,
> you'd include a line like
> boot=/dev/sda14
> replacing /dev/sda14 with the appropriate device name for that partition.
> To install it in the mbr of the first drive,
> boot=/dev/sda or for the second drive, boot=/dev/sdb.
If I change the boot option to /dev/sdb and then run it, will the 2nd
drive work on its own, i.e. when I connect it to the PC alone without
the Mandriva drive connected as /dev/sda. I always confuse the boot
and root options.
mount that drive ie. to /mnt, update /mnt/etc/lilo.conf if needed and then
run "lilo -r /mnt". However you might get problems if the lilo versions on
the drive and Mandrivas version differ.
> LILO is already there. I'm not installing it. It's already the
> bootloader. The problem is I don't have a shell for this drive as it
> boots up directly to the application.
In order to rule out problems with different versions of lilo, I'd
boot into Mandriva, and then chroot to the second drive, and run it's
version of lilo.
The lilo on the second drive may need access to /proc etc. I use
a script to chroot to a different install, after mounting it ...
#!/bin/bash
BackupMountPoint=/mnt/otherlinuxsystem
mkdir -p $BackupMountPoint
mount --bind /proc $BackupMountPoint/proc -o ro
mount --bind /sys $BackupMountPoint/sys -o ro
mount --bind /dev $BackupMountPoint/dev -o ro
chroot $BackupMountPoint
umount $BackupMountPoint/dev
umount $BackupMountPoint/proc
umount $BackupMountPoint/sys
Once you're in the chroot environment, you should be able to run
it's version of lilo.