* [gentoo-user] Strange behaviour with LILO on new install on old laptop
@ 2014-04-19 4:52 Walter Dnes
2014-04-19 5:09 ` covici
0 siblings, 1 reply; 4+ messages in thread
From: Walter Dnes @ 2014-04-19 4:52 UTC (permalink / raw
To: Gentoo Users List
I just finished installing Gentoo on an older AMD laptop. There was
one major problem that I hacked around, and things appear to be working
OK, but I still get warnings when installing lilo.
When I first did the install, I got the warning message...
"Could not determine root partition!". I ran lilo and rebooted, but got
a kernel panic, because the kernel couldn't find the boot device. I dug
into this. Apparently the lilo ebuild tries to outsmart the user, and
figure out the root partition itself, with the bash syntax...
rootpart="$(mount | grep -v "tmpfs" | grep -v "rootfs" | grep "on / " | cut -f1 -d " ")"
I don't know if I screwed up during the install, but *IN THE CHROOT*,
mount returns a null string. I remembered vaguely that "mount" returns
the contents of /etc/mtab. I looked at it, and /etc/mtab was also
empty. I applied the "rootpart=" stuff against another machine, and
found out which line it homed in on. I manually edited /etc/mtab in
the chroot, inserting the short line...
805
...Then I emerged lilo again. This time I got...
#####################################################################
>>> Installing (1 of 1) sys-boot/lilo-23.2-r2
* Checking for LILO ... Yes, on /dev/sda
* Running DOLILO to complete the install ...
You can move /etc/conf.d/dolilo.example to /etc/conf.d/dolilo and edit it to set your preferences.
fdisk: cannot open 80: No such file or directory
fdisk: cannot open 80: No such file or directory
Bootsector updated succesfully.
#####################################################################
The important part is that the laptop now boots up OK. However, when I
re-install lilo, on the natively-booted laptop, I still get the above
messages. I'm using the same partitioning scheme and fstab that I've
been using for years without problems. Here they are...
outfput from "fdisk -l"
#####################################################################
Disk /dev/sda: 320.1 GB, 320072933376 bytes, 625142448 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x612cf108
Device Boot Start End Blocks Id System
/dev/sda1 2048 625142447 312570200 5 Extended
/dev/sda5 4096 618495 307200 83 Linux
/dev/sda6 620544 17397759 8388608 83 Linux
/dev/sda7 17399808 625142447 303871320 83 Linux
#####################################################################
/etc/fstab
#########################################################################
/dev/sda5 / ext2 noatime,nodiratime,async 0 1
/dev/sda7 /home ext3 noatime,nodiratime,async 0 1
/home/bindmounts/opt /opt auto bind 0 0
/home/bindmounts/var /var auto bind 0 0
/home/bindmounts/usr /usr auto bind 0 0
/home/bindmounts/tmp /tmp auto bind 0 0
/dev/sda6 none swap sw 0 0
/dev/cdrom /mnt/cdrom iso9660 noauto,users,ro 0 0
/dev/sr0 /mnt/dvd auto noauto,users,ro 0 0
devpts /dev/pts devpts defaults 0 0
#########################################################################
Any ideas?
--
Walter Dnes <waltdnes@waltdnes.org>
I don't run "desktop environments"; I run useful applications
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [gentoo-user] Strange behaviour with LILO on new install on old laptop
2014-04-19 4:52 [gentoo-user] Strange behaviour with LILO on new install on old laptop Walter Dnes
@ 2014-04-19 5:09 ` covici
2014-04-19 11:32 ` Walter Dnes
0 siblings, 1 reply; 4+ messages in thread
From: covici @ 2014-04-19 5:09 UTC (permalink / raw
To: gentoo-user
Walter Dnes <waltdnes@waltdnes.org> wrote:
> I just finished installing Gentoo on an older AMD laptop. There was
> one major problem that I hacked around, and things appear to be working
> OK, but I still get warnings when installing lilo.
>
> When I first did the install, I got the warning message...
> "Could not determine root partition!". I ran lilo and rebooted, but got
> a kernel panic, because the kernel couldn't find the boot device. I dug
> into this. Apparently the lilo ebuild tries to outsmart the user, and
> figure out the root partition itself, with the bash syntax...
>
> rootpart="$(mount | grep -v "tmpfs" | grep -v "rootfs" | grep "on / " | cut -f1 -d " ")"
>
> I don't know if I screwed up during the install, but *IN THE CHROOT*,
> mount returns a null string. I remembered vaguely that "mount" returns
> the contents of /etc/mtab. I looked at it, and /etc/mtab was also
> empty. I applied the "rootpart=" stuff against another machine, and
> found out which line it homed in on. I manually edited /etc/mtab in
> the chroot, inserting the short line...
>
> 805
>
> ...Then I emerged lilo again. This time I got...
>
> #####################################################################
> >>> Installing (1 of 1) sys-boot/lilo-23.2-r2
>
> * Checking for LILO ... Yes, on /dev/sda
> * Running DOLILO to complete the install ...
> You can move /etc/conf.d/dolilo.example to /etc/conf.d/dolilo and edit it to set your preferences.
> fdisk: cannot open 80: No such file or directory
> fdisk: cannot open 80: No such file or directory
> Bootsector updated succesfully.
> #####################################################################
>
> The important part is that the laptop now boots up OK. However, when I
> re-install lilo, on the natively-booted laptop, I still get the above
> messages. I'm using the same partitioning scheme and fstab that I've
> been using for years without problems. Here they are...
>
> outfput from "fdisk -l"
> #####################################################################
> Disk /dev/sda: 320.1 GB, 320072933376 bytes, 625142448 sectors
> Units = sectors of 1 * 512 = 512 bytes
> Sector size (logical/physical): 512 bytes / 512 bytes
> I/O size (minimum/optimal): 512 bytes / 512 bytes
> Disk identifier: 0x612cf108
>
> Device Boot Start End Blocks Id System
> /dev/sda1 2048 625142447 312570200 5 Extended
> /dev/sda5 4096 618495 307200 83 Linux
> /dev/sda6 620544 17397759 8388608 83 Linux
> /dev/sda7 17399808 625142447 303871320 83 Linux
> #####################################################################
>
> /etc/fstab
> #########################################################################
> /dev/sda5 / ext2 noatime,nodiratime,async 0 1
> /dev/sda7 /home ext3 noatime,nodiratime,async 0 1
> /home/bindmounts/opt /opt auto bind 0 0
> /home/bindmounts/var /var auto bind 0 0
> /home/bindmounts/usr /usr auto bind 0 0
> /home/bindmounts/tmp /tmp auto bind 0 0
> /dev/sda6 none swap sw 0 0
> /dev/cdrom /mnt/cdrom iso9660 noauto,users,ro 0 0
> /dev/sr0 /mnt/dvd auto noauto,users,ro 0 0
>
> devpts /dev/pts devpts defaults 0 0
> #########################################################################
>
> Any ideas?
I don't let theebuild muck with lilo.conf,I edit it myself, so the root
is no problem -- its an initrd anyway.
--
Your life is like a penny. You're going to lose it. The question is:
How do
you spend it?
John Covici
covici@ccs.covici.com
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [gentoo-user] Strange behaviour with LILO on new install on old laptop
2014-04-19 5:09 ` covici
@ 2014-04-19 11:32 ` Walter Dnes
2014-04-19 11:35 ` covici
0 siblings, 1 reply; 4+ messages in thread
From: Walter Dnes @ 2014-04-19 11:32 UTC (permalink / raw
To: gentoo-user
On Sat, Apr 19, 2014 at 01:09:25AM -0400, covici@ccs.covici.com wrote
>
> I don't let theebuild muck with lilo.conf,I edit it myself, so the root
> is no problem -- its an initrd anyway.
I don't understand. The ebuild doesn't look at lilo.conf, rather, it
tries to guess the root partition, and fails miserably from the chroot.
--
Walter Dnes <waltdnes@waltdnes.org>
I don't run "desktop environments"; I run useful applications
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [gentoo-user] Strange behaviour with LILO on new install on old laptop
2014-04-19 11:32 ` Walter Dnes
@ 2014-04-19 11:35 ` covici
0 siblings, 0 replies; 4+ messages in thread
From: covici @ 2014-04-19 11:35 UTC (permalink / raw
To: gentoo-user
Walter Dnes <waltdnes@waltdnes.org> wrote:
> On Sat, Apr 19, 2014 at 01:09:25AM -0400, covici@ccs.covici.com wrote
> >
> > I don't let theebuild muck with lilo.conf,I edit it myself, so the root
> > is no problem -- its an initrd anyway.
>
> I don't understand. The ebuild doesn't look at lilo.conf, rather, it
> tries to guess the root partition, and fails miserably from the chroot.
>
> --
> Walter Dnes <waltdnes@waltdnes.org>
> I don't run "desktop environments"; I run useful applications
I don't let the ebuild build my lilo.conf at all, I build it myself, it
never runs dolilo.
--
Your life is like a penny. You're going to lose it. The question is:
How do
you spend it?
John Covici
covici@ccs.covici.com
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-04-19 11:35 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-04-19 4:52 [gentoo-user] Strange behaviour with LILO on new install on old laptop Walter Dnes
2014-04-19 5:09 ` covici
2014-04-19 11:32 ` Walter Dnes
2014-04-19 11:35 ` covici
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox