Gentoo Logo
Gentoo Spaceship




Note: Due to technical difficulties, the Archives are currently not up to date. GMANE provides an alternative service for most mailing lists.
c.f. bug 424647
List Archive: gentoo-embedded
Navigation:
Lists: gentoo-embedded: < Prev By Thread Next > < Prev By Date Next >
Headers:
To: <gentoo-embedded@g.o>
From: <chris@...>
Subject: Re: gentoo baselayout "Attempted to kill init"
Date: Fri, 22 Apr 2011 08:34:35 -0500
 On Fri, 22 Apr 2011 08:00:35 +0200, Jörg Faschingbauer 
 <joerg.faschingbauer@...> wrote:
> On Thu, 2011-04-21 at 16:18 -0500, chris@... wrote:
>> I've got a filesystem created with the following toolchain: (from
>>  crossdev)
>>
>>  arm-unknown-linux-gnu-
>>
>>  with
>>
>>  arm-unknown-linux-gnu-emerge system
>>  arm-unknown-linux-gnu-emerge baselayout
>>
>>  I created the kernel separately, and was able to boot it with 
>> another
>>  filesystem that was created by somebody else.
>>
>>  During the boot process the kernel says "Attempted to kill init"
>>  because the /init program exited for some reason.
>>  The problem is that I can't get any other error from the init 
>> program.
>>  I have no idea why it's exiting. It could be a missing library, 
>> segfault
>>  or bad invocation, so I have no idea where to start.
>
> Provided that /init is an executable:
>
> If the instruction set that the root filesystem was compiled for 
> doesn't
> match your architecture's, then it's an "illegal instruction" signal
> that bites init. This usually happens quite early, before any
> configuration error is seen.
>
> You can verify this by building your own busybox-only tree with the 
> same
> toolchain you built the kernel with. Choose a static build
> (CONFIG_STATIC, "Busybox Settings"/"Build Options"/"blah static 
> blah").
> Copy init and all that it needs (glibc?) over from your real rootfs 
> into
> your small tree. Boot the kernel into the small tree, passing it
> init=/bin/sh (which is busybox). Call /init and see what happens.
>
> Alternatively, you could augment your tree with busybox, by 
> installing
> it into it. Boot into the tree, but with init=/bin/sh (the augmented
> busybox).
>
> Have fun,
> Joerg

 You were right about the "Illegal Instruction". I booted the working 
 filesystem and chrooted into the new one where I was able to play around 
 with the "broken" init file.

 I'm guessing I stuck a bad flag in make.conf, since the same compiler 
 was able to produce a working kernel.

 Thanks.


References:
gentoo baselayout "Attempted to kill init"
-- chris
Re: gentoo baselayout "Attempted to kill init"
-- Jörg Faschingbauer
Navigation:
Lists: gentoo-embedded: < Prev By Thread Next > < Prev By Date Next >
Previous by thread:
Re: gentoo baselayout "Attempted to kill init"
Next by thread:
crossdev conflict between sys-libs/glibc and cross-arm-unknown-linux-gnueabi/glibc?
Previous by date:
Re: gentoo baselayout "Attempted to kill init"
Next by date:
crossdev conflict between sys-libs/glibc and cross-arm-unknown-linux-gnueabi/glibc?


Updated Jun 25, 2012

Summary: Archive of the gentoo-embedded mailing list.

Donate to support our development efforts.

Copyright 2001-2013 Gentoo Foundation, Inc. Questions, Comments? Contact us.