initramfs problem - /init file

raul.moreno at raul.moreno at
Fri Feb 22 03:05:59 EST 2008

Hi Dave,

I have just figured out the problem... an stupid error... By mistake I took
the filesystem compiled to intel instead to ppc. I guess I forgot to assign
the right cross-compile toolchain. So the microprocessor can't execute the
init file.

Now it works.
Anyway thank you for your time.

Raúl Moreno

"David H. Lynch Jr." <dhlii at dlasys.lcl>
"David H. Lynch Jr."
21/02/2008 16:31
Por favor, responda a dhlii
 Para:   raul.moreno at                                                                               
 cc:     linuxppc-embedded <linuxppc-embedded at>                                                              
 Asunto: Re: initramfs problem - /init file                                                                            

raul.moreno at wrote:
> Hello Dave,
> thanks for your answer. I agree with you, the easy way is to assign the
> rootfs directory. I gave the filesystem as a cpio file because it is the
> same (the kernel takes the rootfs and converts it to a cpio format), but
> the compilation is faster. Anyway, although now I do as you said, I still
> get the error:
> "Failed to execute /init
> Kernel panic - not syncing: No init found.  Try passing init= option to
> kernel."
> I can't understand why it happens. I check the permission of /init and
> /sbin/init and everything seems to me OK.
> Any idea?
    I have had the same problem.
    Things I can remember:
          console setup,
          watch out for symbolic links to init.
          Also is your init and executable or  script ?
          I think you get this failure if ANYTHING goes wrong exec'ing
             Like - it found init but could not execute a shell.
             or the shell required a library it could not find.
          Or something is not quite right with your Virtual memory -
            Linux exec's by forcing chained page faults.

       One thing I tried was a simple "hello world" in ppc assembler -
no libraries,
       and named it /init. When it succeeded I was able to narrow my
problem down..
       Then tried a "hello world" in C with a static library, then
dynamic, then ...
       Basically building more and more complex /init's until I isolated
what was failing.

> Raúl Moreno

Dave Lynch
     DLA Systems
Software Development:
Embedded Linux
717.627.3770                    dhlii at
fax: 1.253.369.9244                                               Cell:
Over 25 years' experience in platforms, languages, and technologies too
numerous to list.

"Any intelligent fool can make things bigger and more complex... It takes a
touch of genius - and a lot of courage to move in the opposite direction."
Albert Einstein

More information about the Linuxppc-embedded mailing list