Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Solved - Lilo panics when using disklabel
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
FastTurtle
Guru
Guru


Joined: 03 Sep 2002
Posts: 409
Location: Shake & Bake

PostPosted: Fri Apr 19, 2013 3:34 pm    Post subject: Solved - Lilo panics when using disklabel Reply with quote

This is annoying: for some reason, lilo wont/can't use the
Code:
LABEL=boot
yet I need this functional as this is a Live-USB (flash drive) that is supposed to be usable on any x86_64 system as I can't ensure the drive is always designated the same way (/dev(sd/hd##) depending on the system.

I can for testing purposes go back to the /dev/sdg1

Here's my lilo.conf

boot=/dev/sdg1

This at least avoids a
chroot $ /sbin/lilo
Warning: LBA32 addressing assumed
Fatal: raid_setup: stat("LABEL=flashboot")


prompt
timeout=50
default=gentoo

image="LABEL=flashboot/kernel-genkernel-x86_64-3.4.40"
label=gentoo
read-only
append="real_root=flashgentoo"
initrd=/flashboot/initramfs-genkernel-x86_64-3.4.40

Here's the command I'm running
Code:

chroot $ nano /etc/lilo.conf
chroot $ /sbin/lilo -P IGNORE-TABLE
Warning: LBA32 addressing assumed
Warning: /dev/sdg1 is not on the first disk
Warning: Device 0x0860: Inconsistent partition table, 1st entry
  CHS address in PT:  73:0:5  -->  LBA (1117926)
  LBA address in PT:  2048  -->  CHS (0:33:3)
Warning: The partition table is *NOT* being adjusted.
Fatal: open LABEL=flashboot/kernel-genkernel-x86_64-3.4.40: No such file or directory


Edit:

Well I've at least fixed the blasted boot = LABEL issue

You need to use the full path /dev/disk/by-label/xxxx in line 1 (boot=/" for sbin to install. Then the standard /boot path for your entries.


Last edited by FastTurtle on Fri Apr 19, 2013 4:15 pm; edited 1 time in total
Back to top
View user's profile Send private message
eccerr0r
Advocate
Advocate


Joined: 01 Jul 2004
Posts: 3894
Location: USA

PostPosted: Fri Apr 19, 2013 3:50 pm    Post subject: Reply with quote

Technically it shouldn't be a problem if the kernel you want to use is on the actual media... The installed bootloader knows that the kernel it's about to load is on the same media that the boot sector was read from as it's also lilo - the paths are meaningless and it's hardcoded as a LBA into the lilo boot sectors. The rootfs is a different story however, the kernel itself needs to find it and the boot loader can only hint at it.

If you want to load a kernel from another media than the boot media, I'd suggest to use grub or something. While it also cannot deal with labels (labels are only valid after the kernel is loaded and userspace applications are available), it can easily boot off of other disks at whim.

Is this the same media you were talking about in another thread? Is the filesystem on this media fat32? I'd suggest something other than lilo if this is the case... On fat32 and iso9660 filesystems I've seen a lot of setups using syslinux. I use grub most of the time.
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed to be advocating?
Back to top
View user's profile Send private message
FastTurtle
Guru
Guru


Joined: 03 Sep 2002
Posts: 409
Location: Shake & Bake

PostPosted: Fri Apr 19, 2013 4:19 pm    Post subject: Reply with quote

First off, this is an AMD64 build so grub isn't an option (unless static flag is used). I'm also not a fan of grub as it doesn't work on all hardware unlike Lilo. The only time Lilo has failed is when there's an actual config problem for me or something went "boom" during the mbr installation.

Formating is ext2 and it looks as though I solved the label issue with Lilo. Have to provide the full path "/dev/disk/by-label/flashboot" works.

As I stated in my edit, you don't need to edit anything else as the /dev/disk/by-label/ tells lilo where everything is at though I still need to test it. Got no warnings other then the usual on the disk isn't the first boot drive.
Back to top
View user's profile Send private message
eccerr0r
Advocate
Advocate


Joined: 01 Jul 2004
Posts: 3894
Location: USA

PostPosted: Fri Apr 19, 2013 4:39 pm    Post subject: Reply with quote

Grub works fine on my x86_64 systems... and it works on all of my x86 hardware too. I have USB media booting grub just fine - and one particular external HDD that will boot off of USB or SATA via grub. I've deprecated lilo completely at this point because grub is so much more flexible at booting media - I can use a USB grub install to boot a kernel off a hard disk I added after installing grub.
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed to be advocating?
Back to top
View user's profile Send private message
FastTurtle
Guru
Guru


Joined: 03 Sep 2002
Posts: 409
Location: Shake & Bake

PostPosted: Sun Apr 21, 2013 10:55 pm    Post subject: Reply with quote

I did switch the USB build over to grub and although the boot did not finish, I'm pretty confident that it will once I can test further. It at least got to the point of detecting the usb mouse and keyboard but paused after that. Probably the rootwait option that wasn't needed (do you know how long that pause is?)

After doing lots of reading, I discovered that lilo is not disk-label aware, thus it's no longer an option for me nor is grub while grub2 is. Because of this, I'll eventually move to grub2 for my bootloader as it'll do what I want.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum