0

I'm trying to reinstall something on my new kernel of Ubuntu 16.04 system. And I accidentally tried the command: sudo update initramfs -u Since then, my computer could not boot correctly anymore. Every time, it will enter the busybox, just like:

BusyBox v1.21.1 (Ubuntu 1:1.21.0-1ubuntu1) built-in shell (ash) enter 'help' for a list of built-in commands.

(initramfs)

More importantly, I could not type in anything under this circumstance.

Right now, I am able to use my computer via another kernel. But does anyone have some good ideas to fix my issue? Thanks.

Here is the output of ls -al /boot

total 158540  
drwxr-xr-x  4 root root     4096 Apr  7 12:28 .  
drwxr-xr-x 24 root root     4096 Apr  7 07:01 ..  
-rw-r--r--  1 root root   217286 Apr  5  2019 config-4.15.0-48-generic  
-rw-r--r--  1 root root   217465 Feb 28 12:24 config-4.15.0-91-generic  
-rw-r--r--  1 root root   217465 Apr  1 01:44 config-4.15.0-96-generic   
drwx------  3 root root     4096 Dec 31  1969 efi  
drwxr-xr-x  5 root root     4096 Apr  7 12:30 grub  
-rw-r--r--  1 root root 55577646 Aug 28  2019 initrd.img-4.15.0-48-generic  
-rw-r--r--  1 root root 56163066 Mar 18 06:25 initrd.img-4.15.0-91-generic  
-rw-r--r--  1 root root 12625827 Apr  7 12:28 initrd.img-4.15.0-96-generic   
-rw-r--r--  1 root root   182704 Jan 28  2016 memtest86+.bin  
-rw-r--r--  1 root root   184380 Jan 28  2016 memtest86+.elf  
-rw-r--r--  1 root root   184840 Jan 28  2016 memtest86+_multiboot.bin  
-rw-------  1 root root  4051368 Apr  5  2019 System.map-4.15.0-48-generic  
-rw-------  1 root root  4067536 Feb 28 12:24 System.map-4.15.0-91-generic  
-rw-------  1 root root  4068326 Apr  1 01:44 System.map-4.15.0-96-generic  
-rw-------  1 root root  8141400 Apr  8  2019 vmlinuz-4.15.0-48-generic  
-rw-------  1 root root  8193432 Mar  1 05:28 vmlinuz-4.15.0-91-generic  
-rw-------  1 root root  8191544 Apr  6 12:08 vmlinuz-4.15.0-96-generic

I tried sudo update-initramfs -c -k 4.15.0-96-generic
but it did not help.

my terminal screenshot

The updated output of ls -al /boot:

total 158540

drwxr-xr-x  4 root root     4096 Apr  7 16:25 .  
drwxr-xr-x 24 root root     4096 Apr  7 07:01 ..  
-rw-r--r--  1 root root   217286 Apr  5  2019 config-4.15.0-48-generic  
-rw-r--r--  1 root root   217465 Feb 28 12:24 config-4.15.0-91-generic  
-rw-r--r--  1 root root   217465 Apr  1 01:44 config-4.15.0-96-generic  
drwx------  3 root root     4096 Dec 31  1969 efi  
drwxr-xr-x  5 root root     4096 Apr  7 12:30 grub  
-rw-r--r--  1 root root 55577646 Aug 28  2019 initrd.img-4.15.0-48-generic  
-rw-r--r--  1 root root 56163066 Mar 18 06:25 initrd.img-4.15.0-91-generic  
-rw-r--r--  1 root root 12625839 Apr  7 16:25 initrd.img-4.15.0-96-generic  
-rw-r--r--  1 root root   182704 Jan 28  2016 memtest86+.bin  
-rw-r--r--  1 root root   184380 Jan 28  2016 memtest86+.elf  
-rw-r--r--  1 root root   184840 Jan 28  2016 memtest86+_multiboot.bin  
-rw-------  1 root root  4051368 Apr  5  2019 System.map-4.15.0-48-generic  
-rw-------  1 root root  4067536 Feb 28 12:24 System.map-4.15.0-91-generic  
-rw-------  1 root root  4068326 Apr  1 01:44 System.map-4.15.0-96-generic  
-rw-------  1 root root  8141400 Apr  8  2019 vmlinuz-4.15.0-48-generic  
-rw-------  1 root root  8193432 Mar  1 05:28 vmlinuz-4.15.0-91-generic  
-rw-------  1 root root  8191544 Apr  6 12:08 vmlinuz-4.15.0-96-generic  
3
  • Boot to a bootable kernel, and type ls -al /boot and edit that output into your question, and I'll see if I can help. Why did you do the update-initramfs command? What were you trying to reinstall on your kernel? Start commands to me with @heynnema or I may miss them.
    – heynnema
    Apr 7, 2020 at 17:31
  • @heynnema Hi heynnema, thanks for the reply. I just attached the output in my question. It's a long story why I tried update-initramfs command. My Nvidia driver crashed and I tried to reinstall it. However, there was a compiler issue with my installation file. I searched on the Internet and found an answer which told me to use that command. But I do not remember exactly what the command is used for.
    – Uio96
    Apr 7, 2020 at 19:34
  • Please see my answer. If it's helpful, please remember to accept it by clicking the checkmark icon that appears just to the left of my answer. Thanks!
    – heynnema
    Apr 7, 2020 at 20:02

1 Answer 1

0

Your initrd.img-4.15.0-96-generic file is corrupt. And you can see that the file size is quite different from the -48 and -91 versions.

-rw-r--r--  1 root root 55577646 Aug 28  2019 initrd.img-4.15.0-48-generic  
-rw-r--r--  1 root root 56163066 Mar 18 06:25 initrd.img-4.15.0-91-generic  
-rw-r--r--  1 root root 12625827 Apr  7 12:28 initrd.img-4.15.0-96-generic   

To fix:

In terminal...

sudo update-initramfs -c -k 4.15.0-96-generic

Then do...

ls -al /boot/initrd*

And compare file sizes. They should be close. If they are, try and reboot to the -96 kernel, and it should boot.

11
  • Hi heynnema, thanks for the answer. I tried your commands. But it seemed that the size did not change. It was wired to me. I attached the screenshot in my question. Could you take a look?
    – Uio96
    Apr 7, 2020 at 20:21
  • @ClarkLin I don't understand "It was wired to me.". Also, show me the entire ls -al /boot again. Copy/paste the output as an edit to your question, like the first time that you did that. Thanks!
    – heynnema
    Apr 7, 2020 at 20:26
  • Thanks, I have attached the new output. I said "It was wired to me" because I believed you had found the problem and the command should work but it did not.
    – Uio96
    Apr 7, 2020 at 20:33
  • Yes, that should have fixed it. The file is 1/4 the size it should be. When you say "I'm trying to reinstall something on my new kernel of Ubuntu 16.04 system." what exactly do you mean? I also assume that -96 didn't boot, correct?
    – heynnema
    Apr 7, 2020 at 21:17
  • Yep, you're right. The issue is with my -96 kernel. As I said in my previous comment, I tried many times to reinstall the Nvidia driver in that kernel. I eventually gave up and turned to my -91 kernel. I remembered that I also tried sudo apt-get purge Nvidia* before. I'm not sure if that is related to this issue.
    – Uio96
    Apr 7, 2020 at 21:23

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .