Using GRUB 2

Slashdot it! Delicious Share on Facebook Tweet! Digg!

Installation and Configuration

The Ubuntu installer automatically installs GRUB 2. Thanks to the so-called "OS prober," GRUB independently recognizes the operating systems on the hard drive and creates entries for them. If you modify the /etc/default/grub [3] central configuration file (menu.lst no longer exists), the system has to read the settings in again, which – as mentioned earlier  – you accomplish with the sudo update-grub command. You can also use tools such as Grub Customizer [4] or GRUB 2 Editor for the same purpose.

GRUB 2 Splash Image

One way to customize GRUB 2 is with a splash image (Figure 2), but to ensure that no harm is done, secure the entire /etc/grub.d/ directory with administrator rights. The directory contains all scripts that define GRUB 2 behavior, so the bootloader starts properly in an alphanumeric sequence. In a pinch, grab the original configuration by starting an Ubuntu Live CD and mounting the external hard drive by double-clicking it in the file manager.

Figure 2: GRUB doesn't accept just any image as a splash image. You can install a few using a package.

Splash images have to meet certain criteria [5]. They must be in PNG, JPG/JPEG, or TGA format; consist of a maximum 256 RGB colors; and can't be indexed. Although you can set these criteria with GIMP, you have an easier way. To install a few sample images for GRUB 2, enter the command:

$ sudo apt-get install grub2-splashimages

Next, copy one of the images to the /boot/grub directory (e.g., an Apollo spaceship image):

$ sudo cp /usr/share/images/grub/Apollo_17_The_Last_Moon_Shot_Edit1.tga/boot/grub/

If GRUB finds multiple images, it takes the first one in alphanumeric order. To integrate the image permanently, use the command:

$ sudo update-grub

The image should appear as a splash image in the GRUB 2 screen output.

Buy this article as PDF

Express-Checkout as PDF

Pages: 4

Price $0.99
(incl. VAT)

Buy Ubuntu User

SINGLE ISSUES
 
SUBSCRIPTIONS
 
TABLET & SMARTPHONE APPS
Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

  • Encrypted ZFS with Ubuntu

    ZFS is one of the most advanced filesystems, and now it can be used natively on Linux. One drawback is that native ZFS encryption is not available, but this article shows how use Linux's disk encryption to install Ubuntu onto an encrypted disk with ZFS.

  • Installing Ubuntu 13.10

    Ubuntu 13.10 offers some changes to the installation process. We'll walk you through upgrading or installing the latest release.

  • Installing Ubuntu 13.10

    Ubuntu 13.10 offers some changes to the installation process. We'll walk you through upgrading or installing the latest release.

  • Installing Ubuntu 14.04

    Ubuntu 14.04 offers some changes to the installation process. We'll walk you through upgrading or installing the latest release.

  • Installing Ubuntu 12.10

    Ubuntu 12.10 offers a few changes to the installation process. We'll walk you through upgrading or installing the latest release.