LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (http://www.linuxquestions.org/questions/slackware-14/)
-   -   Can i set lilo.conf boot from different linux kernel? (http://www.linuxquestions.org/questions/slackware-14/can-i-set-lilo-conf-boot-from-different-linux-kernel-4175451697/)

gabytf 02-25-2013 08:56 PM

Can i set lilo.conf boot from different linux kernel?
 
i am multiboot with LILO for Slackware 14.0, -current.

I created lilo.conf when i last install Slackware-current.

My problem is when i select to boot slackware 14.0, it boot and bring me to the "darkstar login:", after that i can not have any access to my keyboard to type commands. i force shut down.

However,i can boot-in to Slackware14 using USB boot stick.

One thing i noticed is my Slackware Current is Linux 3.2.26, it use .26 to boot the Slackware14 but when i boot with USB stick it use Linux 3.2.29 and it boot smoothly.

How to correct my lilo.conf so that my slackware14 will boot with Linux 3.2.29 instead of 3.2.26?

Quote:

# LILO configuration file
# generated by 'liloconfig'
#
# Start LILO global section
# Append any additional kernel parameters:
append=" vt.default_utf8=0"
boot = /dev/sda

# Boot BMP Image.
# Bitmap in BMP format: 640x480x8
bitmap = /boot/slack.bmp
# Menu colors (foreground, background, shadow, highlighted
# foreground, highlighted background, highlighted shadow):
bmp-colors = 255,0,255,0,255,0
# Location of the option table: location x, location y, number of
# columns, lines per column (max 15), "spill" (this is how many
# entries must be in the first column before the next begins to
# be used. We don't specify it here, as there's just one column.
bmp-table = 60,6,1,16
# Timer location x, timer location y, foreground color,
# background color, shadow color.
bmp-timer = 65,27,0,255

# Standard menu.
# Or, you can comment out the bitmap menu above and
# use a boot message with the standard menu:
#message = /boot/boot_message.txt

# Wait until the timeout to boot (if commented out, boot the
# first entry immediately):
prompt
# Timeout before the first entry boots.
# This is given in tenths of a second, so 600 for every minute:
timeout = 1200
# Override dangerous defaults that rewrite the partition table:
change-rules
reset
# Normal VGA console
vga = normal
# Ask for video mode at boot (time out to normal in 30s)
#vga = ask
# VESA framebuffer console @ 1024x768x64k
#vga=791
# VESA framebuffer console @ 1024x768x32k
#vga=790
# VESA framebuffer console @ 1024x768x256
#vga=773
# VESA framebuffer console @ 800x600x64k
#vga=788
# VESA framebuffer console @ 800x600x32k
#vga=787
# VESA framebuffer console @ 800x600x256
#vga=771
# VESA framebuffer console @ 640x480x64k
#vga=785
# VESA framebuffer console @ 640x480x32k
#vga=784
# VESA framebuffer console @ 640x480x256
#vga=769
# End LILO global section


# Windows bootable partition config begins
other = /dev/sdb2
label = Win7
table = /dev/sdb
# Windows bootable partition config ends
# Linux bootable partition config begins
image = /boot/vmlinuz
root = /dev/sda7
label = SlackCurrent
#Hibernate
append="resume=/dev/sda5"
read-only
# Linux bootable partition config ends
# Linux bootable partition config begins
image = /boot/vmlinuz
root = /dev/sda6
label = SlackStable
read-only
# Linux bootable partition config ends

astrogeek 02-25-2013 10:40 PM

The problem is that when you run lilo from -current, with the following lines for your Slackware-14 boot...

Code:

# Linux bootable partition config begins
image = /boot/vmlinuz
root = /dev/sda6
label = SlackStable
read-only
# Linux bootable partition config ends

... it maps your -current /boot/vmlinuz as the boot kernel for Slackware 14.

If you want -current to manage the MBR then you have two choices:

1. Mount the slackware-14 kernel so it is visible from -current, then change lilo.conf to use it for the Slackware-14 boot stanza
2. Create a lilo.conf within Slackware-14 to install lilo to its own partition, then chain boot that from -current

The first one might be done like this (provide your own paths)

Code:

mount /dev/sda6 /mnt/slack14

lilo.conf:

# Linux bootable partition config begins
image = /mnt/slack14/boot/vmlinuz
root = /dev/sda6
label = SlackStable
read-only
# Linux bootable partition config ends

For the second option to chain boot Slackware-14, in your Slackware-14 lilo.conf set the following:

Code:

boot = /dev/sda6

# Linux bootable partition config begins
image = /boot/vmlinuz
root = /dev/sda6
label = SlackStable
read-only
# Linux bootable partition config ends

...then run lilo from Slackware 14, and in your -current lilo.conf change Slackware-14 stanza to:

Code:

# Linux bootable partition config begins
other = /dev/sda6
label = SlackStable

...then run lilo from -current

[EDIT]
I always prefer the chain boot methods for my own systems.

That way, there is never any confusion about which OS instance owns the MBR, and no requirement to mount other boot partitions when I run lilo.
[/EDIT]

gabytf 02-26-2013 04:14 AM

Hey it works. I take the second choice.
Thank you astrogeek!


All times are GMT -5. The time now is 07:42 PM.