[BusyBox] urgent help at change_root inside of initrd

Stephan Linz linz at MAZeT.de
Fri Feb 15 09:07:04 UTC 2002


Am Freitag, 15. Februar 2002 13:27 schrieben Sie:
> On Fri, 15 Feb 2002 11:52:47 +0100, Stephan Linz <linz at MAZeT.de> wrote:
> >echo CHANGE ROOT TO 0x101:
> >echo 0x101 >/proc/sys/kernel/real-root-dev
> >sleep 10
> >#umount /proc
> >cho TRY TO EXECUTE /sbin/init
> >exec /sbin/init
>
> I think that this way linuxrc process does not die, so that root is not
> changed

Yes, it seems linuxrc isn't die. Further I found two unexpected effects.

First, I  lose the root=/dev/ram init=/linuxrc stuff at lilo.conf. If the 
kernel is comming up and the initrd image was loading I got next message:

init: applet not found

I know it's a generall error message of BusyBox whenever missing an compiled 
in applet like mkdir or chroot. In normal case I would expect this message, 
becouse it's true. I don't compile in the init applet. I don't need it on my 
pre-root FS. But why is init call. I expect the run of /linuxrc first and 
however the kernel message of missing init binary 
is missing to?  Is there an known bug inside of BusyBox ? I use BusyBox 0.51


Second case, I left only the init=/linuxrc stuff at lilo.conf. So the kernel 
is booting and /linuxrc will run. Corrently my linuxrc is very small. For 
debugging I've made a physical root partition (minix fs) at /dev/hda3 and the 
main work of initrd/linuxrc is to comming up there; see next:

#!/bin/sh
mount -n -t proc none /proc
echo CHANGE ROOT TO 0x303:
echo 0x303 >/proc/sys/kernel/real-root-dev
umount /proc
echo My PID $$
exit 0

So I found out, that the PID of /linuxrc isn't zero like expected (PID is 1). 
Why ? Is there any configuration of BusyBox I have to do to avoid this two 
conditions ?

Thanks for any help ...
Stephan


>
> -- snip --



-- 

======================================================================
Stephan Linz
Software Engineer

MAZeT GmbH                   Email:   mailto:linz at mazet.de
Branche office Jena          Phone:   +49-3641-2809-55
Göschwitzer Straße 32        Fax  :   +49-3641-2809-12
D-07745 JENA
Germany

Visit our web-pages: http://www.MAZeT.de
======================================================================



More information about the busybox mailing list