How To Fix A Broken Initrd Image in Linux-1
How To Fix A Broken Initrd Image in Linux-1
Linux
Today, we'll show you how you can fix your broken or accidentally
deleted Initrd Image ie. Linux Kernel Image and GRUB Loader in your
Ubuntu installed machine. It should also work for Ubuntu derivatives
as well as other distribution.
(https://linoxide.com/wp-content/uploads/2014/11/initrd-not-found.
png)
As we know, "When there is will there is way". Yes, we can fix or
rebuild the initrd image. In my case I will be showing you with my
Ubuntu 13.10 Operating System.
Here are easy step wise steps below with screenshots which will help
us rebuild our corrupted Kernel Image (Initrd)
$ sudo fdisk -l
Here, from above result, in my case, sda1 is the one I need to mount.
After Chroot is done, we will be backing up the image file of initrd, you
can see the image files under /boot.
# ls /boot/*initrd*
or
# ls /lib/modules/
You will be able to get the version of the kernel you have currently in
the system from the above command.
# mv /boot/initrd.img-3.11.0.12-generic
/boot/old-initrd.img-3.11.0.12-generic-old
Note: the file format of the initrd image may differ from Ubuntu to
Fedora Based Systems.
If your initrd image has been deleted, you won't be able to run the
above command hence, can't create its backup.
The above command works for the other distributions like CentOS,
Fedora, Hat,etc not for Ubuntu
# update-initramfs -c -k 3.11.0.12-generic
# grub2-mkconfig -o /boot/grub2/grub.cfg
# update-grub
# exit
Your email address will not be published. Required fields are marked *
Name * Email *
Submit Your Comment