[Unionfs] UNIX domain sockets fail in RHEL5 patched unionfs

Craig Johnston agspoon at gmail.com
Fri Mar 13 17:37:23 EDT 2009


Erez,

Thank you for the offer of help.  I'll try to give you whatever you need.

The SRPM for the RHEL5 (5.3) kernel we are using is located here,
ftp://ftp.redhat.com/pub/redhat/linux/enterprise/5Server/en/os/SRPMS/kernel-2.6.18-128.1.1.el5.src.rpm

This includes the kernel .config file (we are using the SMP i386
kernel).  If this form doesn't work for you, I can create a tarball
for you.

We started with the 2.5.1 patch for 2.6.18.8.  And modeled our changes
on the unionfs-2.4_for_2.6.18-RHEL5.diff.gz that is located on the
UnionFS download server.

We had to muck around with the lookup_one_len() symbol (breaking the
kernel API :( ), and found a couple of areas where RH had patched the
kernel forward.

In vfs_path_lookup(), we needed to change the call to audit_inode() as
the parameters changed.  Also changed the signature of
unionfs_filldir() and readdir_util_callback() to make the ino
parameter a u64.

The LOOKUP_ONE #define had to be changed to (0x1000) to avoid
conflicting with LOOKUP_ATOMIC (128 (or 0x80)).  Note the RHEL5 patch
moved this to 256, but I think that conflicted with LOOKUP_OPEN
(0x0100 or (256)).  I don't know why the confusing change in base for
the #defines in namei.h ;)

I've attached the complete patch we applied to the stock kernel if you
are interested.

Thanks,
Craig


On Tue, Mar 10, 2009 at 9:20 AM, Erez Zadok <ezk at cs.sunysb.edu> wrote:
>
> In message <f4f856dc0903031620y2e9559c8sa5b65f6bc9780d36 at mail.gmail.com>, Craig Johnston writes:
>
> > We have patched a RHEL5 (5.3) kernel with the latest 2.5.1 unionfs patches.
> > We started with the 2.6.18.8 patch set, and modified it until it went into
> > RH's heavily modified kernel.  We didn't have to do do much (most remove
> > stuff that RH already had).
> >
> > In the end, things seem to work Ok except that UNIX domain sockets that are
> > created within a unionfs writeable layer do not work.  They can be created
> > (nc -lU /var/run/mysocket), but we receive an ECONNREFUSED when the client
> > tries to connect (nc -U /var/run/mysocket).
> [...]
>
> Craig, I've not heard from others of having problems with domain sockets.
> Maybe there's something else in the rhel kernel which is preventing them
> from working.  It's also possible that something went wrong during the hand
> application of the unionfs patch to the rhel kernel.
>
> Can you send me a tarball with the unmodified rhel5.3 kernel sources, and
> your kernel .config file?  I'll apply the unionfs patch carefully and test
> it here to ensure that it passes my regression suite, including the tests
> for sockets.
>
> Cheers,
> Erez.
>
> PS. does anyone know if there's a git repo of the rhel kernel, being kept
> somewhere and up-to-date (preferably one that isn't git-rebase'd).  If I had
> access to one, it'd be easier for me to keep up-to-date a set of unionfs
> patches against the latest rhel kernels (it's a popular request).
-------------- next part --------------
A non-text attachment was scrubbed...
Name: unionfs-2.5.1RHEL5.patch
Type: text/x-diff
Size: 376278 bytes
Desc: not available
Url : http://www.fsl.cs.sunysb.edu/pipermail/unionfs/attachments/20090313/9129a276/unionfs-2.5.1RHEL5-0001.bin


More information about the unionfs mailing list