Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I use lilo, and have two different kernels. One is newer and use KMS with it.

What I would like to do, is to be able to set vga=xxx for only one of the kernels.

Is this possible?

I would also like to be able to code into lilo.conf options that I pass on the commandline, but am unsure how to do this

edit:

adding my current lilo.conf

append=" vt.default_utf8=0"
boot = /dev/sda
prompt
timeout = 1200
change-rules
  reset
other = /dev/sda1
  label = Windows
  table = /dev/sda
image = /boot/bzImage-2.6.33.2
  root = /dev/sda5
  label = Test
  read-only
image = /boot/bzImage-2.6.31
  root = /dev/sda5
  label = Older
  vga = 791
  read-only
share|improve this question
    
wow, blast from the past. my answer below jives with what i recall from the last decade, but i haven't used LILO in quite some time so i may be forgetting something. –  quack quixote May 4 '10 at 20:33

1 Answer 1

up vote 0 down vote accepted

According to an old LILO manpage you'd use the vga option for one kernel section in your lilo.conf but not the other. Example:

[...]
image = /zImage-1.0.9
        label = 1.0.9

image = /tamu/vmlinuz
        label = tamu
        root = /dev/hdb2
        vga = ask
[...]

The vga parameter can be given any standard response (that is, any value the kernel will understand; I believe LILO will simply pass any value set to the kernel):

vga = mode
This specifies the VGA text mode that should be selected when booting. The following values are recognized (case is ignored):

  • normal: select normal 80x25 text mode.
  • extended (or ext): select 80x50 text mode.
  • ask: stop and ask for user input (at boot time).
  • [number]: use the corresponding text mode. A list of available modes can be obtained by booting with vga=ask and pressing [Enter].

If this variable is omitted, the VGA mode setting contained in the kernel image is used. (And that is set at compile time using the SVGA_MODE variable in the kernel Makefile, and can later be changed with the rdev(8) program.)

For additional kernel options that LILO doesn't understand, use the append keyword in lilo.conf:

[...]
image = /tamu/vmlinuz
        label = tamu
        root = /dev/hdb2
        vga = ask
        append="iwlagn.swcrypto=1"
[...]

Don't forget to rerun LILO after changing lilo.conf to pick up the changes.

share|improve this answer
    
At the moment I have the cga option set for one kernel as per your example, but it currently occurs for every kernel I boot with. Likewise I wanted to add the option iwlagn.swcrypto=1 for a particular kernel, but running lilo just results in an error. Rather than have the option on a operate line, should I have it after the path of the kernel? –  Jack May 5 '10 at 1:39
    
@jack: hopefully you mean the vga option... i can't remember, but i think LILO only recognizes a few kernel options in this format. use the append option for others. adding another example now... –  quack quixote May 5 '10 at 1:59
    
Hi quack, thanks, I will try out the append option later, it should solve my problem. However the vga paramter does not work as it should. I have pasted my lilo.conf above, and when I boot test, which is the kernel with KMS enabled, I have to manually tell it to continue whenit complaines about the vga line. Removing it solves the problem... –  Jack May 5 '10 at 5:46
    
NM, got it all sorted, thanks :) –  Jack May 5 '10 at 10:09

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.