Originally written: 9/23/2011; last update: 7/7/2018
This Web page is provided free of charge and with no annoying outside ads; however, I did take time to prepare it, and Web hosting does cost money. If you find this Web page useful, please consider making a small donation to help keep this site up and running. Thanks!
|Donate $1.00||Donate $2.50||Donate $5.00||Donate $10.00||Donate another value|
This page is part of my Managing EFI Boot Loaders for Linux document. If a Web search has brought you to this page, you may want to start at the beginning.
The EFI Linux Loader (ELILO) is the oldest and most stable EFI boot loader for Linux. It's similar to the old Linux Loader (LILO) BIOS boot loader, so Linux old-timers should find ELILO familiar. Unfortunately, work on the program stopped in 2013. It still works, but it's no longer provided with most Linux distributions and it may eventually break. ELILO does not explicitly support Secure Boot, which is an increasingly important limitation. Overall, ELILO is a poor choice for most installations, but you can use it if you like.
I've had little success using ELILO on my 32-bit Intel-based Mac Mini, but it works well on three 64-bit UEFI-based PCs and both 32- and 64-bit VirtualBox setups. I've also seen reports online of ELILO working on Macs, so I suspect there's a model-specific problem with my system, or perhaps a Mac configuration quirk I haven't mastered.
Overall, conditions when you might want to consider using it include:
Conditions in which you should almost certainly not use ELILO include:
Because of its obsolescence and limitations, I can't recommend ELILO for general use. It's of interest mainly to those who are nostalgic about LILO. Its principle advantage—easy manual configuration—is shared by other programs, such as gummiboot/systemd-boot and, in a different way, rEFInd.
ELILO installation works just as described in EFI Boot Loader Installation. Some distributions include scripts that are intended to help with the file copying and configuring required by ELILO, but in my experience, these scripts often get things badly wrong. Therefore, I recommend not using them. Because the scripts sometimes run automatically when you upgrade your kernel, it's probably best to install ELILO from binary or source tarball rather than from a distribution's package. (The package file available from the ELILO Sourceforge download page includes binary .efi files for three architectures and a source code tarball.) On the other hand, perhaps the bugs I've encountered will be fixed by the time you read this, or perhaps your distribution will have a better package. (I encountered the worst problems with OpenSUSE, as I recall.)
ELILO installation requires at least two files: The elilo.efi boot loader program file and the elilo.conf configuration file. (If you install from the official ELILO package, the .efi file will be called elilo-3.14-x86_64.efi or something similar. You can keep this name or rename the file, as you see fit.) In practice, you will probably have to copy your Linux kernel file and its associated initial RAM disk file to the ESP, too. This is because ELILO doesn't include any filesystem drivers, meaning that it's dependent upon the EFI to read the kernel and initial RAM disk files. In fact, I've been unsuccessful at getting ELILO to read a kernel from anything other than its installation partition, although the documentation claims it can be done.
If you must store your kernels on a partition other than the ESP, you may be able to use an EFI filesystem driver to give the EFI access to another partition, then store ELILO, the kernel, and its initial RAM disk file on that partition. I've written a page on EFI drivers as part of the documentation for rEFInd, so you should consult that page if you need more information on this topic.
In case you're not familiar with Linux kernels and initial RAM disks, these files are typically stored in /boot:
A fresh Linux installation might provide just one kernel and initial RAM disk file, but some installations have two or more if they've downloaded updates or provide kernel options at boot time. If possible, you may want to copy all of these files to the ESP. Storing the files in the same directory as elilo.efi can slightly simplify the task of configuring the boot loader.
To sum up, the files in a working ELILO configuration will look something like this:
$ ls -l /boot/efi/EFI/ELILO/ total 27855 -rwxr-xr-x 1 root root 3769632 2011-05-22 00:07 bzImage-3.4.0 -rwxr-xr-x 1 root root 362 2011-09-22 00:47 elilo.conf -rwxr-xr-x 1 root root 241451 2011-05-20 21:31 elilo.efi -rwxr-xr-x 1 root root 14034535 2011-05-20 21:34 initrd.img-3.4.0 -rwxr-xr-x 1 root root 5950985 2011-05-22 00:08 initrd.img-3.6.3-8-generic -rwxr-xr-x 1 root root 4523936 2011-05-20 21:34 vmlinuz-3.4.0
Your system might have fewer or more kernel files and initial RAM disk files, but you should have at least one of each, in addition to an elilo.efi file (perhaps under another name) and an elilo.conf file.
ELILO's configuration file, elilo.conf, is similar to that of LILO. An example, taken from a working configuration, looks like this:
prompt timeout=50 default=340 #chooser=textmenu #message=textmenu-message.msg image=vmlinuz-3.6.3-8-generic label=linux initrd=initrd.img-3.6.3-8-generic read-only root=/dev/sda4 append="" image=/EFI/ubuntu/bzImage-3.4.0 label=340 initrd=/EFI/ubuntu/initrd.img-3.4.0 read-only root=/dev/sda4 append="reboot=a,w"
You can cut and paste this example and modify it for your own needs. Some key points when you make your modifications include the following:
When ELILO is launched, you'll see one of two things, assuming everything's working correctly:
If you set a short enough timeout, you can simply do nothing and the default kernel will boot right away. This might be sensible if you seldom need to select anything but the default option. Pressing a key should delay the boot process in the event you do need to select another option.
If your distribution includes scripts to maintain ELILO automatically, and if those scripts work, you shouldn't need to do much to maintain this boot loader. As noted earlier, though, in my experience these auto-maintenance scripts are often worse than useless. Thus, you may need to keep your ELILO configuration up to date when you upgrade your kernel or ELILO itself. This task involves copying the updated files to the ESP and making changes to elilo.conf.
If you install an updated kernel, I strongly recommend that you add that kernel to the ESP, and entries for it to your elilo.conf file, rather than replace working files and entries. Once you've rebooted into the new kernel, if you're satisfied that it works, you can delete the old kernel and initial RAM disk file and remove its entry from elilo.conf. If you delete these entries, and especially the files themselves, and the new ones don't work, you may find it difficult to boot your system to correct the problem. (One of the advantages of EFI, though, is that a full implementation includes a shell that you can use to edit configuration files and make changes, so some such problems can be easier to correct on an EFI system than on a BIOS system. In the EFI shell, type edit filename to edit the specified file.)
Go on to "Using SYSLINUX"
Return to "Managing EFI Boot Loaders for Linux" main page
copyright © 2011–2018 by Roderick W. Smith
If you have problems with or comments about this web page, please e-mail me at firstname.lastname@example.org. Thanks.
Return to my main Web page.