[klibc] difference between busybox and klibc (faq?)
octane indice
octane at alinto.com
Sat Mar 29 09:44:07 PDT 2008
En réponse à maximilian attems <max at stro.at> :
> > My goal is to have a minimalistic kernel, with initramfs
> > inside, that can be used to boot everyPC everywhere,
> > as soon they have network access.
>
> why a minimalistic kernel?
> what do you understand by that?
By minimalistic, I want to say: only one file. And size would be
the second focus in mind.
> a kernel that boots everywhere has many modules builds and
> thus may not be considered minimalistic. you should weight
> which goal you want to persue.
>
First goal: boot from a lot of place. It means for me:
all NIC modules (builtin or module). Yes, I know it's a
lot of things. It means for some more things:
utilities given by klibc, and some more (fuse come
to mind)
> > So: kernel boots, initramfs load. But I read everywhere
> > that 2.6 kernels needs a bootloader. If I load initramfs
> > inside kernel, can I drop the bootloader? Almost
> > everything in the command line can be loaded inside
> > initramfs, so the bootloader is useless?
>
> no the bootloader puts initramfs in mem and tells the kernel
> the start and end of it's memory. you are confusing things.
>
Well. English is not my native language, maybe I'm
explaining things badly. I will try to explain that as
clearly as I can:
I read that bootloader are mandatory for 2.6 kernels.
I'm asking why it's mandatory.
I read that's because only bootloader knows how
to give arguments to the kernel, especially the
root one.
Now, lets take an example. I boot my kernel with:
linux root=/dev/hda1 ro
If I drop these options, kernel won't know where to
load the rootfs. But this information can be put
inside initramfs:
linux initrd=initramfs.file
and Inside the initramfs:
mount -t ext3 -o ro /dev/hda1 /mnt
exec run-init /mnt /sbin/init "$@"
I boot the same way, with the same arguments, but bootloader
looks a bit useless.
Now, If I put initramfs totally in my kernel, the bootloader is
like that:
linux
and boot loader is totally useless.
So, I'm asking: do the bootloader is still mandatory?
My goal is to have as less thing as possible. If a bootloader
is mandatory, I will use it. If I can get rid off this way,
I drop it.
> > Then the initramfs would drop a menu. (at first, a shell)
> > this menu asks you where is the root filesystem.
> > then it mount it and continues to boot.
>
> hmm the bootloader usualy passes the root args that
> are then interpreted by initramfs. letting the user
> decide that seems like a risky job.
>
yes, it's not intended for everyone, it's at first for
me, and next for a demonstration. When I will
understand good what's happening in these moments
and how it's happening, maybe I will try to do
something more specifc and with less interaction.
> > I want to test it with nfs, then nfs over wireless links,
> > nfs over ipsec, then use it with fuse filesystem like
> > sshfs or httpfs or any combination of these.
>
> joy.
>
It means that's theorically possible? I'm wondering
how fuse is breaking (or not) things.
> > Eventually, make a 2-time boot by loading a more recent
> > kernel witk kexec, or with more capacities.
> >
> > Are these questions related to this list?
>
> yes.
>
Ok, I continue, then.
> ------------------- Fin du message d'origine ---------------------
Eurolines : Voyagez au meilleur prix : http://www.alinto.com/pub/
More information about the klibc
mailing list