How to build a working unionfs-kernel for live cd

Asked by Andreas Heinlein

I am trying to build a customised live CD based on the Ubuntu 8.04 CD with a customised kernel. However, I have not been able to build a working kernel 2.6.24 with unionfs and squashfs.

I tried the following:
- Use the Ubuntu linux sources from package linux-source-2.6.24 and patch them with the official unionfs and squashfs patches. This did not work for unionfs, the patch had two rejects which I tried to solve, but the kernel did not compile.
- Use the same linux-source-2.6.24 and build the modules outside the kernel tree using the packages squashfs-source and unionfs-source. Again, this worked for squashfs but not for unionfs. Unionfs has a duplicate declaration of vfs_listxattr which seems to be a long-known bug (see https://bugs.launchpad.net/ubuntu/+source/linux-source-2.6.20/+bug/119590), so it will not compile (not even with disabling extended attributes for ext2/ext3, xfs and jfs in the kernel).
- Use vanilla sources 2.6.24.7 and patch them with the official patches. This patches and compiles fine, but udev crashes on startup, obviously in a function called skb_release_all. After the udev crash, gdm does not work becaues it is missing some device files.
- As a last resort, I tried the same with vanilla 2.6.24.5 because the unionfs patches are declared to apply to this kernel, even though I would not like to use a kernel with known security holes. But the same as above, it does not boot.

Kernel compilation and building was always done with make-kpkg, but I think this does not make a difference.

So how in the world are the guys at Canonical building the kernel for their live CDs? I noticed that they're still using unionfs 1.4, which was officially only supported up to 2.6.18. Is there a reason for this? Thank you very much.

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
Andreas Heinlein
Solved:
Last query:
Last reply:
Revision history for this message
Launchpad Janitor (janitor) said :
#1

This question was expired because it remained in the 'Open' state without activity for the last 15 days.

Revision history for this message
Andreas Heinlein (aheinlein) said :
#2

Just FYI - I found the solution myself. See here:
http://www.candelatech.com/oss/ubuntu-live-notes.txt

In short - get the source package of the kernel and ubuntu-modules (with apt-get source linux-image-2.6.24-19-generic linux-ubuntu-modules-2.6.24-19-generic) and rebuild them adapted to your needs. The source package includes a debian/rules section to build custom flavours, that was exactly what I needed.

Revision history for this message
Andreas Heinlein (aheinlein) said :
#3

Oops, see above.