[BusyBox] making some progress with "minit", but "genext2fs" is the villain now
Robert P. J. Day
rpjday at mindspring.com
Thu Mar 25 17:14:03 UTC 2004
On Thu, 25 Mar 2004, Manuel Novoa III wrote:
> You might want to look at
> http://uclibc.org/cgi-bin/cvsweb/buildroot/sources/genext2fs.patch
i'm not sure what i'm supposed to see there -- there's no obvious mention
of FIFO support listed there. i don't want to absolutely bore people here
to tears fighting with minit, i'm happy to move this to the actual minit
mailing list if it's more appropriate there. but after reviewing what's
happening with minit on my system, here's a summary of the issues
regarding minit in BB-1.00-pre8 that i've found:
1) the routine minit_main() tries to open the files /etc/minit/{in,out}.
only by looking at a sample /etc/minit directory did i realize that one
could have named pipes by these names, so i created them, but genext2fs
wouldn't add them to the ramdisk i was creating. bummer.
however, looking at minit.c, it doesn't seem like not having those
files would be a fatal error. according to the code:
if (infd < 0 || outfd < 0) {
puts("minit: could not open /etc/minit/in or /etc/minit/out\n");
sulogin();
nfds = 0;
} else
pfd.fd = infd;
pfd.events = POLLIN;
so it certainly seems that minit would still keep rolling right along,
even without these files. so that doesn't explain the kernel panic
right after that message.
2) again, from looking at minit.c, it seems like i can run it after a
normal boot with init, as a regular app. note the code:
infd = open("/etc/minit/in", O_RDWR);
outfd = open("/etc/minit/out", O_RDWR | O_NONBLOCK);
if (getpid() == 1) {
int fd;
i_am_init = 1;
...
sure seems like this allows for minit to *not* act as init, PID 1.
should i conclude that i can run minit from the command line after the
boot? that would be an interesting variation.
3) genext2fs and named pipes. yeah, i've flogged that sufficiently for
now.
thoughts?
rday
More information about the busybox
mailing list