Kernel updates are vital for security and feature additions. But if not performed with caution, these updates can render your server unavailable or down.
In our role as Outsourced Tech Support services for web hosts, kernel updates are a commonly performed task in servers.
Today, we’ll discuss the error ‘Error 15: File not Found’ that occurs in CentOS servers when trying to boot after changes in grub.
‘Error 15 file not found’ in CentOS server – Causes
The error ‘Error 15: File not found’ happens when you try to boot a server with the updated kernel after a kernel update or patch.
Error 15: File not Found Press any key to continue
This error is caused due to some issues with the GRUB, which is the boot loader used in CentOS servers.
The main reasons why you get this error 15 are:
1. Wrong entries in GRUB
In majority scenarios, the ‘Error 15: File not Found’ issue pops up due to an incorrect entry in the GRUB boot loader configuration file at /boot/grub/menu.lst .
A typical entry in GRUB menu for CentOS 6 servers looks like:
title CentOS (2.6.18-238.19.1.el5PAE) root (hd0,0) kernel /vmlinuz-2.6.18-238.19.1.el5PAE ro root=LABEL=/ initrd /initrd-2.6.18-238.19.1.el5PAE.img title CentOS (2.6.18-238.9.1.el5PAE)
The cause for the error 15 can be anything from an incorrect drive, wrong path or partition name, or any other mistakes in this kernel entry in the GRUB menu.
By default, the kernel images are found in /boot partition. In servers where the partition system is different, these paths have to be changed accordingly in GRUB menu.
2. Corrupt GRUB configuration file
A GRUB configuration can get corrupt during system updates. When GRUB is installed in the wrong partition, the system will not be able to boot at all.
If the required modules are missing in the expected /boot partition, system cannot boot. The MBR (Master Boot Record) can get damaged when a secondary OS is installed.
In some cases, the initrd declaration or kernel path may be missing for any listed kernels in the GRUB menu. This will prevent the server from booting into that kernel.
3. Defective hard disk
“Error 15 file not found” may also occur in CentOS servers due to change in BIOS settings, changes in hardware or errors in hard disk.
In the case of servers with multiple hard disks or OS installations, there are chances of creating multiple boot partitions and GRUB mixing up between them.
‘Error 15 file not found’ in CentOS server – Fixes
Depending on the scenario faced and the level of access to the server, we follow different methodologies to fix the error 15.
1. Fixing GRUB entries
When customers contact us saying their server fails to boot due to Error 15, we boot the server into rescue mode and access it via remote console such as IPMI or web portal.
Once the boot prompt loads, we edit the GRUB entries and fix the error. In cases where GRUB is fully corrupt, we reinstall the bootstrap code and then boot the server.
2. Test reboots
In the server where we perform kernel updates or patches, we take adequate backups. We configure GRUB with a fail-over entry to avoid a boot failure.
This fall back configuration ensures that even if a new kernel doesn’t boot due to any errors, there is a fall back working kernel entry which will boot and make the server available.
3. Hard disk inspection
To rule out ‘error 15 file not found’ in CentOS servers due to hard disk errors, we conduct periodic audits to see if there are any bad sectors or other errors.
For servers with messed up hard disks or OS installations, we backup the data and perform re-partition or re-installation as necessary, to fix the errors.
GRUB errors pop up mainly during kernel updates. Today we saw how our Support Engineers resolve and fix ‘Error 15 file not found’ in CentOS servers.