On 7/2/07, Simon Geard <[EMAIL PROTECTED]> wrote: > On Sun, 2007-07-01 at 00:34 +1200, Simon Geard wrote: > > On Sat, 2007-06-30 at 08:55 +0200, Lauri Kasanen wrote: > > > Initramfs is a cpio archive, see the kernel docs. > > > > Not very clear - I've read the kernel docs, and while they provide a > > perfectly good techncial explanation of what an initramfs is, they > > doesn't really offer much information on setting one up. But I've just > > spotted an entry in LFS Hints that looks a little more useful (assuming > > it's still accurate). > > Hmmm. I'm not all that illuminated by the various documentation I've > found. Research suggests three alternatives for populating the > initramfs: > > 1. standard glibc-linked executables and libraries, copied from the > regular system. > > 2. using busybox and a static-linked udevd. > > 3. same as 2, but with klibc instead. > > Can anyone who's actually built an initramfs comment on which of these > options they're using? Most of the distros seem to provide some form of > mkinitramfs script, but all seem to take different approaches - e.g > Redhat seems to be option 1, Debian seems to be option 2...
You're in luck. Bryan has been putting together a mkinitramfs script for LFS that I think will try to land post-6.3 (whenever that happens). Follow this thread: http://linuxfromscratch.org/pipermail/lfs-dev/2007-June/059512.html On my system, I use klibc, but if you don't care about size too much, just use glibc. It's easier to get started. My current initramfs is ~1MB. I wouldn't care if that grew to accommodate glibc. The way I "detect" the rootfs is by embedding fstab into the initramfs and parsing it out if root= hasn't been passed on the kernel command line. I'm not sure how that works when using syslinux. Here's the initramfs Alexander uses on the LiveCD with syslinux: http://wiki.linuxfromscratch.org/livecd/browser/trunk/packages/initramfs/init.in -- Dan -- http://linuxfromscratch.org/mailman/listinfo/blfs-support FAQ: http://www.linuxfromscratch.org/blfs/faq.html Unsubscribe: See the above information page
