[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

building initramfs also as root filesystem problem



Hi,

I am building a linux os by incorporating in-kernel initramfs, which
also runs as root-filesystem.
The result of this work would be booting/distributing linux with only
one file, which is the kernel + linked in initramfs + rootfs.
I am having a problem booting up the os when everything is linked in.
Here is the two errors I've been getting when:

1.  root-filesystem is prepared in initramfs and linked in with kernel
 (total size is about 5 megs) -
    a.  Kernel Panic - not syncing: Attempted to kill init!
    b.  Also tried to boot directly to bash instead (rdinit=/bin/init
and/or init=/bin/sh), same error.

2.  Moved root-filesystem to boot-drive (/rootfs), boot kernel with
linked in initramfs (total size about 2 megs) -
    a.  Boot OK to bash (still within initramfs shell).
    b.  Manually and successfully mount:  rootfs on boot-drive located
at <boot drive>/rootfs to /tmp/rootfs  as vfat filesystem-type
    c.  I can cat all mounted files at /tmp/rootfs.  For example, cat
/tmp/rootfs/bin/clear works find.
    d.  However, I can not execute that file, for example execute
/tmp/rootfs/bin/clear.  Bash would display an error like   clear: no
such file or directory.
    e.  Permission setting is correct of-course.


This is really an effort of building linux distribution from scratch
and compact it into one single file, and not related to Debian at all.
If anyone has experience on this, please give me some advices.


Thank you.

-toan


Reply to: