After my wonderful experience with febootstrap and and gzipped kernel modules I just wanted to post a little information about it. febootstrap uses insmod, it seems because insmod is required for building the initrd, while modprobe can read in gzipped kernel modules, insmod cannot. This means that there are two solutions to the problem, one would be to make febootstrap copy all of the modules to another location and gunzip them if they are zipped, then load the modules from the other location. Another solution would be to patch insmod to support gzipped kernel mods, and then the changes to febootstrap would be quite menial, and insmod would be more in line with current kernel capabilities. For now I have solved the problem with this script for the Arch Linux package, and while this is VERY dirty, it gets libguestfs running now on Arch: https://github.com/thatch45/archpkgs/blob/master/libguestfs/libguestfs.install So I am wondering what everyone thinks the best approach would be here, so that I can start down a more viable path for getting this fixed. Thanks -Thomas S Hatch -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://listman.redhat.com/archives/libguestfs/attachments/20110311/5c003f66/attachment.htm>
On Fri, Mar 11, 2011 at 09:54:15AM -0700, Thomas S Hatch wrote:> After my wonderful experience with febootstrap and and gzipped kernel > modules I just wanted to post a little information about it. > > febootstrap uses insmod, it seems because insmod is required for building > the initrd, while modprobe can read in gzipped kernel modules, insmod > cannot. This means that there are two solutions to the problem, one would be > to make febootstrap copy all of the modules to another location and gunzip > them if they are zipped, then load the modules from the other location. > Another solution would be to patch insmod to support gzipped kernel mods, > and then the changes to febootstrap would be quite menial, and insmod would > be more in line with current kernel capabilities. > > For now I have solved the problem with this script for the Arch Linux > package, and while this is VERY dirty, it gets libguestfs running now on > Arch: > https://github.com/thatch45/archpkgs/blob/master/libguestfs/libguestfs.install > > So I am wondering what everyone thinks the best approach would be here, so > that I can start down a more viable path for getting this fixed.I'm sure the Arch boot initrd/initramfs must have already solved this. Could you take a look inside one, eg: zcat /boot/initrd-XXX.img | cpio -itv # view files zcat /boot/initrd-XXX.img | cpio -id # unpack it Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones virt-df lists disk usage of guests without needing to install any software inside the virtual machine. Supports Linux and Windows. http://et.redhat.com/~rjones/virt-df/
On Fri, Mar 11, 2011 at 04:27:01PM -0700, Thomas S Hatch wrote:> -rwxr-xr-x 1 root root 1432888 Feb 17 21:47 /lib/libc-2.13.so[...]> -rwxr-xr-x 1 root root 136040 Jan 5 19:05 /sbin/modprobeThat appears to be a regular glibc (or at least the size of the glibc is roughly consistent with what I'd expect). We could go this route, but with recent changes to qemu we are very limited in the size of the initrd[1]. I think uncompressing the small number of *.ko.gz files is the easier option right now ... Rich. [1] Thread of doom: http://www.mail-archive.com/kvm at vger.kernel.org/msg39172.html -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones libguestfs lets you edit virtual machines. Supports shell scripting, bindings from many languages. http://libguestfs.org