May 27, 2008 - Old    Comments Off on Ubuntu Boot Options

Ubuntu Boot Options

[size=130:37wu18ib]When and How to Use[/size:37wu18ib]

There are at least two major cases where one may wish to use boot options.
Case 1: When trying to install, and the install freezes.
Case 2: After a system has been installed and does not boot or the system needs adjustment.

[size=130:37wu18ib]When installing[/size:37wu18ib]

When your installer/live CD loads you will come to this page:
[img:37wu18ib]http://i18.tinypic.com/6tzzndc.jpg[/img:37wu18ib]
Go ahead and hit the [b:37wu18ib]F6[/b:37wu18ib] key.
After you hit [b:37wu18ib]F6[/b:37wu18ib] you will see a screen that looks like this:
[img:37wu18ib]http://i16.tinypic.com/7wonyxj.jpg[/img:37wu18ib]
Simply append the options you want to the end of the line. This will mean that you get to turn off or alter the way the machine boots. Here is an example of adding an option:
[img:37wu18ib]http://i17.tinypic.com/8bz22ir.jpg[/img:37wu18ib]

[size=130:37wu18ib]For Installed Systems That Need Adjustment[/size:37wu18ib]

This will explain how to edit the grub menu entries on the fly (not permanently).
This assumes of course that have installed grub, the default boot loader in Ubuntu. (This article does not deal with alternatives like lilo.)
As the machine starts to boot you get a Grub message, at this time press the [b:37wu18ib]ESC[/b:37wu18ib] key. This drops you to a text menu. Choose the boot option you want to work with. Navigate using the the up and down arrow keys. (Cursor key.)

When you have selected the menu item press ‘e’.

Then you will be presented with a “root” line on the first line. You must then move to the “kernel” line one down from there with the down arrow. then again you press ‘e’.

Go to the end of the line (ctrl-E) and add the command from below.

Press the enter key when you are done with the changes, and finally press ‘b’ to boot.

Your machine will now start to boot.

[size=130:37wu18ib]Options for the boot command line[/size:37wu18ib]

This list is not comprehensive but it contains some of the common options. When presented with the text on the screen “boot:” then the options below can be given. They must have the kernel name before the option.

Example: Adding the vga=771 option
boot: /boot/vmlinuz-2.6.15-26-k7 root=/dev/hda1 ro quiet splashboot: /boot/vmlinuz-2.6.15-26-k7 root=/dev/hda1 ro quiet splash vga=771
Options can be used together such as in this example:
/boot/vmlinuz-2.6.15-26-k7 root=/dev/hda1 ro quiet splash noapic nolapic Kernel Options

These options are used by the kernel, and will apply to any system at any time. The file “Documentation/kernel-parameters.txt” in the relevant linux-source package provides more information.
[TABLE][TR][TD]
[b:37wu18ib]Option[/b:37wu18ib][/TD][TD]
[b:37wu18ib]Impact[/b:37wu18ib][/TD][/TR][TR][TD]
vga=xxx[/TD][TD]
Set your[url=http://en.wikipedia.org/wiki/Linux_framebuffer:37wu18ib]framebuffer[/url:37wu18ib] resolution to VESA mode xxx. Check [url=http://en.wikipedia.org/wiki/VESA_BIOS_Extensions#Linux_video_mode_numbers:37wu18ib]here[/url:37wu18ib] for a list of possible modes.[/TD][/TR][TR][TD]
acpi=off OR noacpi[/TD][TD]
This parameter disables the whole ACPI system. This may prove very useful, for example, if your computer does not support ACPI or if you think the ACPI implementation might cause some problems (for instance random reboots or system lockups).[/TD][/TR][TR][TD]
acpi=force[/TD][TD]
Activates the ACPI system even if your computer BIOS date is older than 2000. This parameter overwrites acpi=off and can also be used with current hardware if the ACPI support is not activated despite apm=off.[/TD][/TR][TR][TD]
pci=noacpi OR acpi=noirq[/TD][TD]
These parameters disable the PCI IRQ routing[/TD][/TR][TR][TD]
pci=acpi[/TD][TD]
This parameter activates the PCI IRQ routing[/TD][/TR][TR][TD]
acpi_irq_balance[/TD][TD]
ACPI is allowed to use PIC interrupts to minimize the common use of IRQs.[/TD][/TR][TR][TD]
acpi_irq_nobalance[/TD][TD]
ACPI is not allowed to use PIC interrupts.[/TD][/TR][TR][TD]
acpi=oldboot[/TD][TD]
Deactivates the ACPI system almost completely; only the components required for the boot process will be used.[/TD][/TR][TR][TD]
acpi=ht[/TD][TD]
Impact Deactivates the ACPI system almost completely; only the components required for hyper threading will be used.[/TD][/TR][TR][TD]
noapic[/TD][TD]
Disable the “Advanced Programmable Interrupt Controller (APIC)”.[/TD][/TR][TR][TD]
nolapic[/TD][TD]
Disable the “local APIC”.[/TD][/TR][TR][TD]
apm=off OR noapm[/TD][TD]
Disable the Advanced Power Management.[/TD][/TR][TR][TD]
irqpoll[/TD][TD]
Changes the way the kernel handles interrupt calls (set it to [url=http://en.wikipedia.org/wiki/Asynchronous_I/O:37wu18ib]polling[/url:37wu18ib]). Can be useful in case of hardware interrupt issues.[/TD][/TR][/TABLE]
Initrd break points

These options will cause the initrd to pause execution and spawn a shell. Only one option at a time may be specified (the last wins). See also: /usr/share/initramfs-tools/init and /usr/share/initramfs-tools/scripts/*.
[TABLE][TR][TD]
[b:37wu18ib]Option[/b:37wu18ib][/TD][TD]
[b:37wu18ib]Impact[/b:37wu18ib][/TD][/TR][TR][TD]
break=top[/TD][TD]
Break before any scripts are run (including usplash)[/TD][/TR][TR][TD]
break=modules[/TD][TD]
Break before any modules are loaded[/TD][/TR][TR][TD]
break OR break=premount[/TD][TD]
Break before the premount scripts are run (ie: udev)[/TD][/TR][TR][TD]
break=mount[/TD][TD]
Break before the root partition is mounted[/TD][/TR][TR][TD]
break=bottom[/TD][TD]
Break before the ‘bottom’ scripts are run[/TD][/TR][TR][TD]
break=init[/TD][TD]
Break just before control is handed over to /sbin/init.[/TD][/TR][/TABLE]
(This list is far from complete, please feel free to add some options.)
Installer options (user-land)

These options are usually used when installing a system, and are picked up by the installer program or start-up scripts, and not by the kernel.
[TABLE][TR][TD]
[b:37wu18ib]Option[/b:37wu18ib][/TD][TD]
[b:37wu18ib]Impact[/b:37wu18ib][/TD][/TR][TR][TD]
debian-installer/framebuffer=false[/TD][TD]
Disable framebuffer.[/TD][/TR][TR][TD]
hw-detect/start_pcmcia=false[/TD][TD]
Don’t start PCMCIA. Personal Computer Memory Card International Association, one of the stranger names for a piece of hardware. [img:37wu18ib]http://localgeek.is-a-geek.com/forum/https://help.ubuntu.com/htdocs/ubuntu/img/smile.png[/img:37wu18ib] Your hardware is an association.[/TD][/TR][TR][TD]
netcfg/disable_dhcp=true[/TD][TD]
Force static network config.[/TD][/TR][TR][TD]
bootkbd=uk[/TD][TD]
Set keyboard map. Use a two letter ISO country code to get the right letters on the right keys. This option can help with password problems.[/TD][/TR][/TABLE]
(This list is far from complete, please feel free to add some options.)
Making Permanent changes

Once you know you need to boot with a special option on your installed system, you’ll have to edit the file /boot/grub/menu.lst to make the boot option permanent.
To do this, please do the following:
[code:37wu18ib]
sudo nano /boot/grub/menu.lst
Add the option to the line that starts with “# kopt=”. Then run
sudo update-grub[/code:37wu18ib]
to have the menu entries updated.

NB! If you instead edit the menu entries directly, your changes will magically disappear the next time update-grub is run, for instance when the kernel or grub packages are updated. See [url=https://help.ubuntu.com/community/GrubHowto:37wu18ib]https://help.ubuntu.com/community/GrubHowto[/url:37wu18ib] for more information on configuring grub.