Gentoo Archives: gentoo-user

From: Harry Putnam <reader@×××××××.com>
To: gentoo-user@l.g.o
Subject: [gentoo-user] Re: Need help interpreting kernel panic
Date: Sat, 11 Feb 2017 21:18:20
Message-Id: 86wpcwtoj9.fsf@reader.local.lan
In Reply to: Re: [gentoo-user] Need help interpreting kernel panic by Johannes Rosenberger
1 Johannes Rosenberger <gentoo@×××××.eu> writes:
2
3 > On 11.02.2017 20:47, Rich Freeman wrote:
4 >> On Sat, Feb 11, 2017 at 2:12 PM, Harry Putnam <reader@×××××××.com> wrote:
5 >>> Again I get a kernel panic but this time its different. It seems to
6 >>> mount the disks ok but then fails to find a working `init' command.
7 >>>
8 >>> Checking that with sysrescueCD I see /sbin/init does exist on that new vm.
9 >>> and is executable.
10 >>>
11 >>> The disk setup is sda1=/boot sda2=swap sda3=/home sda4=/
12 >>>
13 >> My guess is that it is mounting the wrong filesystem as root. It
14 >> might be detecting /dev/sdb as /dev/sda. Also, the root device might
15 >> be named /dev/xda4 depending on the kernel/etc. Systemrescuecd isn't
16 >> using the same kernel/etc so it might not see the disks the same way.
17 >>
18 >> An initramfs with root=UUID="505f850e-b26a-4d0f-a02f-6ba573a48ad8" (or
19 >> a label) would be a more reliable way to handle this, or you can
20 >> probably just fiddle with the device names until you stumble on the
21 >> right one.
22 >>
23 >>
24 > Well, if you look at the kernel messages you see that the init is found
25 > but not executable (error -8). I don't know what the error number means, but
26 > have you set CONFIG_BINFMT_ELF and CONFIG_BINFMT_SCRIPT in your .config?
27 > Is /bin/sh executable?
28
29 Error means ENOEXEC I think from browsing a bit on google
30
31 About BINFMT
32
33 Yes. (grepping from chroot at /usr/src/linux/)
34 grep BINFMT .config
35
36 CONFIG_BINFMT_ELF=y
37 CONFIG_BINFMT_SCRIPT=y
38 # CONFIG_BINFMT_AOUT is not set
39 # CONFIG_BINFMT_MISC is not set
40
41
42 I just chrooted and re-emerged sysvinit but no help. From chroot, I
43 ran /sbin/init 3 and it did try to go to runlevel 3 (just brought me
44 out of chroot), so it appears to be working.
45
46 The stuff about `runaway loop' at modprobe (in the kernel messages)
47 seems like it might mean something.
48
49 I think I'll test about modprobe for that module binfmt-46-4c

Replies

Subject Author
Re: [gentoo-user] Re: Need help interpreting kernel panic Johannes Rosenberger <gentoo@×××××.eu>