0

I have a couple of questions concerning qemu boot options

1)

When using the following argument

init=/bin/sh

It works - but is really the init-process replaced by a sh-process?

Qemu-system-x86_64 -hda output/images/rootfs.ext2 -kernel output/images/bzImage --append "root=/dev/sda console=ttyS0 rw init=/bin/sh" -serial stdio > /home/john/kernel_debug_mess.txt

2)

if I use the following option - the system cannot boot

 init=/bin/ls

the following error pops up in the kernel-logg:

 End kernel panic - not syncing: attempted to kill init! exitcode 0x000000000

When using ls - how could the crash be explained?

2
  1. Yes. When you tell the kernel to use /bin/sh as init, then it does exactly what you tell it to.

  2. /bin/ls runs and then exits, so the kernel panics because there is no init process any more. init is supposed to be a long-lasting process.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.