[arch-general] Kernel panic at boot after hard reset: not syncing. No init found.
Hello, I know some people had this problem before but no solution seems to help me. I was playing Kerbal Space Program, the game filled up my RAM, my computer was no longer responding (it happens to me a few times a month if I forgot to close firefox before playing for example). I had to hard shutdown, then on the boot I get this kernel panic. (Here is a screenshot: http://dettorer.net/kernel_panic.jpg) The init= parameter given by grub is correct: /usr/lib/systemd/systemd and I double checked the root= parameter, it is by uuid but I also tried by device name (/dev/sda7) and by label. I use three partitions: sda5: /boot (sda6: swap) sda7: / sda8: /home `fdisk -l /dev/sda` http://paste.awesom.eu/ux8 `ls -l /dev/disk/by-uuid` http://paste.awesom.eu/85U Using the output of a new `grub-mkconfig` didn't fix it either. Here is my grub.cfg: http://paste.awesom.eu/aDR I tried running `mkinitcpio -v -p linux` (I use the 3.8 kernel from core but also tried the 3.9 from testing, same result) Here is my mkinitcpio.conf: http://paste.awesom.eu/yVH and the output of `mkinitcpio -v -p linux` http://paste.awesom.eu/6f3 I checked the filesystems of my / and /boot partitions with badblocks and fsck, no problem from here. (I also tried reformating my swap with mkswap as the second line of kernel panic mention swapper even though I didn't understand that line, I just gave it a try). I don't know what to do now, my guess is that the initramfs can't mount the root partition but the root= parameter is correct and everything mount well under a liveCD (this is from where I try to fix it). PS: It's my first post on arch-general, sorry if my question is off-topic or poorly presented. -- Dettorer
On Mon, May 6, 2013 at 3:41 PM, Paul Hervot <p.hervot@gmail.com> wrote:
Hello, I know some people had this problem before but no solution seems to help me.
I was playing Kerbal Space Program, the game filled up my RAM, my computer was no longer responding (it happens to me a few times a month if I forgot to close firefox before playing for example). I had to hard shutdown, then on the boot I get this kernel panic. (Here is a screenshot: http://dettorer.net/kernel_panic.jpg)
The init= parameter given by grub is correct: /usr/lib/systemd/systemd and I double checked the root= parameter, it is by uuid but I also tried by device name (/dev/sda7) and by label. I use three partitions: sda5: /boot (sda6: swap) sda7: / sda8: /home `fdisk -l /dev/sda` http://paste.awesom.eu/ux8 `ls -l /dev/disk/by-uuid` http://paste.awesom.eu/85U Using the output of a new `grub-mkconfig` didn't fix it either. Here is my grub.cfg: http://paste.awesom.eu/aDR
I tried running `mkinitcpio -v -p linux` (I use the 3.8 kernel from core but also tried the 3.9 from testing, same result) Here is my mkinitcpio.conf: http://paste.awesom.eu/yVH and the output of `mkinitcpio -v -p linux` http://paste.awesom.eu/6f3
Comparing your output to mine, what most intrigues me is that there are a lot of lines that I have and you do not: adding symlink: /usr/lib/libc.so.6 -> libc-2.17.so adding file: /usr/lib/libc-2.17.so adding symlink: /lib/ld-linux-x86-64.so.2 -> ld-2.17.so adding file: /usr/lib/ld-2.17.so Curiously enough, most (or all) of them are from package "glibc", so I'd try first to reinstall this package. Note that you are getting a kernel panic: that is *not* because initramfs fails to mount root. If that were the case you'd get an "early boot prompt". The problem is that the kernel is unable to load the init program from the initramfs itself. My guess is that there are several files missing from the initramfs and so the init program is unable to start. To be totally sure you can try unpacking your initramfs in a temporary file and chroot to it. # mkdir /tmp/foo # cd /tmp/foo # zcat /boot/initramfs-linux.img | cpio -i # chroot . /bin/sh And try several commands to see what happens. HTH -- Rodrigo
On Mon, May 06, 2013 at 06:47:33PM +0200, Rodrigo Rivas wrote:
On Mon, May 6, 2013 at 3:41 PM, Paul Hervot <p.hervot@gmail.com> wrote:
Hello, I know some people had this problem before but no solution seems to help me.
I was playing Kerbal Space Program, the game filled up my RAM, my computer was no longer responding (it happens to me a few times a month if I forgot to close firefox before playing for example). I had to hard shutdown, then on the boot I get this kernel panic. (Here is a screenshot: http://dettorer.net/kernel_panic.jpg)
The init= parameter given by grub is correct: /usr/lib/systemd/systemd and I double checked the root= parameter, it is by uuid but I also tried by device name (/dev/sda7) and by label. I use three partitions: sda5: /boot (sda6: swap) sda7: / sda8: /home `fdisk -l /dev/sda` http://paste.awesom.eu/ux8 `ls -l /dev/disk/by-uuid` http://paste.awesom.eu/85U Using the output of a new `grub-mkconfig` didn't fix it either. Here is my grub.cfg: http://paste.awesom.eu/aDR
I tried running `mkinitcpio -v -p linux` (I use the 3.8 kernel from core but also tried the 3.9 from testing, same result) Here is my mkinitcpio.conf: http://paste.awesom.eu/yVH and the output of `mkinitcpio -v -p linux` http://paste.awesom.eu/6f3
Comparing your output to mine, what most intrigues me is that there are a lot of lines that I have and you do not:
adding symlink: /usr/lib/libc.so.6 -> libc-2.17.so adding file: /usr/lib/libc-2.17.so adding symlink: /lib/ld-linux-x86-64.so.2 -> ld-2.17.so adding file: /usr/lib/ld-2.17.so
Curiously enough, most (or all) of them are from package "glibc", so I'd try first to reinstall this package.
Note that you are getting a kernel panic: that is *not* because initramfs fails to mount root. If that were the case you'd get an "early boot prompt". The problem is that the kernel is unable to load the init program from the initramfs itself. My guess is that there are several files missing from the initramfs and so the init program is unable to start. To be totally sure you can try unpacking your initramfs in a temporary file and chroot to it.
# mkdir /tmp/foo # cd /tmp/foo # zcat /boot/initramfs-linux.img | cpio -i # chroot . /bin/sh
And try several commands to see what happens.
Thank you for your answers. I first tried cleaning /tmp but it is a tmpfs, so it was already empty. I reinstalled glibc, linux, mkinitcpio and mkinitcpio-busybox, ran mkinitcpio and unpacked the initramfs but I can't chroot into it, here is my try: http://paste.awesom.eu/im9 the file bin/sh exists in the initramfs but chroot seems to be unable to find it. Though it seems not to be a problem with grub2, I reinstalled it and generated a new grub.cfg, it still panic. -- Paul `Dettorer` Hervot (hervot_p) EPITA 2016 Membre Prologin | Vice-président GConfs
On Tue, May 7, 2013 at 1:58 AM, Paul Hervot <p.hervot@gmail.com> wrote:
On Mon, May 6, 2013 at 3:41 PM, Paul Hervot <p.hervot@gmail.com> wrote:
Hello, I know some people had this problem before but no solution seems to help me.
I was playing Kerbal Space Program, the game filled up my RAM, my computer was no longer responding (it happens to me a few times a month if I forgot to close firefox before playing for example). I had to hard shutdown, then on the boot I get this kernel panic. (Here is a screenshot: http://dettorer.net/kernel_panic.jpg)
The init= parameter given by grub is correct: /usr/lib/systemd/systemd and I double checked the root= parameter, it is by uuid but I also
by device name (/dev/sda7) and by label. I use three partitions: sda5: /boot (sda6: swap) sda7: / sda8: /home `fdisk -l /dev/sda` http://paste.awesom.eu/ux8 `ls -l /dev/disk/by-uuid` http://paste.awesom.eu/85U Using the output of a new `grub-mkconfig` didn't fix it either. Here is my grub.cfg: http://paste.awesom.eu/aDR
I tried running `mkinitcpio -v -p linux` (I use the 3.8 kernel from core but also tried the 3.9 from testing, same result) Here is my mkinitcpio.conf: http://paste.awesom.eu/yVH and the output of `mkinitcpio -v -p linux` http://paste.awesom.eu/6f3
Comparing your output to mine, what most intrigues me is that there are a lot of lines that I have and you do not:
adding symlink: /usr/lib/libc.so.6 -> libc-2.17.so adding file: /usr/lib/libc-2.17.so adding symlink: /lib/ld-linux-x86-64.so.2 -> ld-2.17.so adding file: /usr/lib/ld-2.17.so
Curiously enough, most (or all) of them are from package "glibc", so I'd try first to reinstall this package.
Note that you are getting a kernel panic: that is *not* because initramfs fails to mount root. If that were the case you'd get an "early boot prompt". The problem is that the kernel is unable to load the init
On Mon, May 06, 2013 at 06:47:33PM +0200, Rodrigo Rivas wrote: tried program
from the initramfs itself. My guess is that there are several files missing from the initramfs and so the init program is unable to start. To be totally sure you can try unpacking your initramfs in a temporary file and chroot to it.
# mkdir /tmp/foo # cd /tmp/foo # zcat /boot/initramfs-linux.img | cpio -i # chroot . /bin/sh
And try several commands to see what happens.
Thank you for your answers.
I first tried cleaning /tmp but it is a tmpfs, so it was already empty. I reinstalled glibc, linux, mkinitcpio and mkinitcpio-busybox, ran mkinitcpio and unpacked the initramfs but I can't chroot into it, here is my try: http://paste.awesom.eu/im9
the file bin/sh exists in the initramfs but chroot seems to be unable to find it.
Hey, we are getting into it... the usual reason for this the error "No such file or directory" when that file does exist is that the ELF interpreter, that is the dynamic loader does not exist. In Arch the dynamic loader is /lib/ld-linux.so.2 for 32-bits and /lib/ld-linux-x86-64.so.2 for 64, and if you look into your initcpio neither of these exist! The most likely reason for these files not being added to your initramfs is that you have lost the "/lib -> usr/lib" symbolic link. The interpreter is actually installed as /usr/lib/ld-linux.so.2 but it is searched as /lib/ld-linux.so.2. I don't know why, but I've seen it happen before. This link is in the package "filesystem" so reinstalling this one and rebuilding the initramfs should solve it. If not, you can create the link yourself: # ln -s usr/lib /lib
Though it seems not to be a problem with grub2, I reinstalled it and
generated a new grub.cfg, it still panic.
-- Paul `Dettorer` Hervot (hervot_p) EPITA 2016 Membre Prologin | Vice-président GConfs
-- Rodrigo
On Tue, May 07, 2013 at 09:34:36AM +0200, Rodrigo Rivas wrote:
Hey, we are getting into it... the usual reason for this the error "No such file or directory" when that file does exist is that the ELF interpreter, that is the dynamic loader does not exist. In Arch the dynamic loader is /lib/ld-linux.so.2 for 32-bits and /lib/ld-linux-x86-64.so.2 for 64, and if you look into your initcpio neither of these exist!
The most likely reason for these files not being added to your initramfs is that you have lost the "/lib -> usr/lib" symbolic link. The interpreter is actually installed as /usr/lib/ld-linux.so.2 but it is searched as /lib/ld-linux.so.2.
I don't know why, but I've seen it happen before. This link is in the package "filesystem" so reinstalling this one and rebuilding the initramfs should solve it. If not, you can create the link yourself:
# ln -s usr/lib /lib
Thanks! That was it. The installation of filesystem was blocked because there was one single folder with one single file in /usr/lib64 : /usr/lib64/kde4/kcm_adobe_flash_player.so I removed it, reinstalled filesystem and regenerated an initramfs, successfully chrooted into it and successfully booted. Probably because of my attempts to fix it, my arch somhow forgot systemd and was booting with initscripts even though I precised `init=/usr/lib/systemd/systemd` on the kernel line. Removing initscript and installing systemd-sysvcompat fixed it, my arch is working fine now, thank you all for your help! -- Paul `Dettorer` Hervot (hervot_p) EPITA 2016 Membre Prologin | Vice-président GConfs
participants (2)
-
Paul Hervot
-
Rodrigo Rivas