Search code examples
linuxkernelbootpanicsyslinux

single partition & no initramfs linux boot gets kernel panic


  • compiled a kernel using gentoo specifications for Thinkpad T430

  • mounted empty ext4 hard drive and created boot/ directory on it, moved bzImage and System.map inside

  • Installed extlinux to it with "extlinux --install [mounted directory]/boot"

  • placed syslinux.cfg inside with the following config:

    DEFAULT linux
      SAY Now booting the kernel from EXTLINUX...
    LABEL linux
      KERNEL /boot/bzImage
      APPEND root=/dev/sdb rw init=/bin/bash
    
  • Created bin/ folder in mounted hard drive, placed bash binary inside

At this point i'm able to boot the kernel to the point where it has to run init, however it panics:

---[ Kernel Panic - not syncing: Requested init /bin/bash failed (error -2). ]---

Solution

  • 4chan solved my question in 10 minutes, i didn't have the libc.so libraries