Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 379865 - sys-apps/acl-2.2.51[nfs] fails acl-2.2.42-CITI_NFS4_ALL-2.dif
Summary: sys-apps/acl-2.2.51[nfs] fails acl-2.2.42-CITI_NFS4_ALL-2.dif
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal with 1 vote (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-08-19 13:56 UTC by Andy Wilkinson
Modified: 2013-12-23 07:34 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info =sys-apps/acl-2.2.51 (emerge-info.log,4.34 KB, text/plain)
2011-08-19 13:57 UTC, Andy Wilkinson
Details
build.log (acl-2.2.51_build.log,1.67 KB, text/plain)
2011-08-19 13:57 UTC, Andy Wilkinson
Details
patch output (acl-2.2.51_acl-2.2.42-CITI_NFS4_ALL-2.dif.out,33.06 KB, text/plain)
2011-08-19 13:58 UTC, Andy Wilkinson
Details
emerge --info =sys-apps/acl-2.2.51 (emerge-info-acl-2-2-51.txt,4.49 KB, text/plain)
2012-05-14 14:29 UTC, Sernin van de Krol
Details
emerge --info =sys-apps/acl-2.2.51 (info.txt,4.99 KB, text/plain)
2012-09-03 20:32 UTC, John Sennesael
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Andy Wilkinson 2011-08-19 13:56:18 UTC
acl-2.2.51 fails to apply patch acl-2.2.42-CITI_NFS4_ALL-2.dif during src_prepare

Reproducible: Always

Steps to Reproduce:
1. emerge =sys-apps/acl-2.2.51
2.
3.
Actual Results:  
Patch fails, emerge aborts

Expected Results:  
Patch succeeds, emerge completes.
Comment 1 Andy Wilkinson 2011-08-19 13:57:21 UTC
Created attachment 283909 [details]
emerge --info =sys-apps/acl-2.2.51
Comment 2 Andy Wilkinson 2011-08-19 13:57:43 UTC
Created attachment 283911 [details]
build.log
Comment 3 Andy Wilkinson 2011-08-19 13:58:07 UTC
Created attachment 283913 [details]
patch output
Comment 4 Sernin van de Krol 2012-05-14 14:26:50 UTC
I'm having the same issue. Build log and patch output are the same, as is the version of acl (2.2.51).
Comment 5 Sernin van de Krol 2012-05-14 14:29:05 UTC
Created attachment 311751 [details]
emerge --info =sys-apps/acl-2.2.51
Comment 6 John Sennesael 2012-09-03 20:29:49 UTC
Ditto :(

ACL's is kind of a major feature of NFS4,... not being able to use them on Gentoo hurts!
Comment 7 John Sennesael 2012-09-03 20:32:13 UTC
Created attachment 322858 [details]
emerge --info =sys-apps/acl-2.2.51
Comment 8 John Sennesael 2012-09-03 20:58:33 UTC
I guess the obvious cause is that the patch is really for acl version 2.2.42 and not for 2.2.51 - fixed with reverting back to the older version.

  emerge =sys-apps/acl-2.2.49 

I masked the newer version in /etc/portage/package.mask

The problem is that upstream has not provided a patch to include nfs support in 2.2.51 yet ( http://www.citi.umich.edu/projects/nfsv4/linux/ )

The 2.2.51 ebuild however shouldn't even attempt to apply the wrong patch, or attempt nfs support at all, even if a user force-unmasks the nfs use flag for acl-2.2.51 - which is what the real bug is...

The upstream website notes:

"Note: Recent linux distributions have included NFSv4/rpcsec_gss support, which may be sufficient for your purposes; Building the following from source should only be necessary if you want to check for bugfixes or need new features in our very latest experimental code.)"

Which might explain the lack of updates on their end. 
At this point I'm not sure what needs to be done to make rpcsec_gss work with nfs on Gentoo (maybe the kereberos use flag adds it?)
Comment 9 John Sennesael 2012-09-04 18:12:27 UTC
This looks very interesting and relevant: http://comments.gmane.org/gmane.linux.file-systems.acl.devel/311

"In general, POSIX and NFSv4 ACLs do not interact very well. The NFSv4 patches 
against libacl which make getfacl and setfacl emulate NFSv4 ACLs are not in 
the upstream version, and never will be. Instead, we'll likely have tools 
that can manipulate NFSv4 ACLs directly. Apparently Gentoo still took the 
CITI libacl patches."

Long story short, as far as I understand, nfs support for posix acl should not exist, and the patch should simply not even be in the ebuild.

But there also do not seem to be any full-featured alternative. 

Wonderful. :(
Comment 10 John Sennesael 2012-09-04 18:27:25 UTC
Aaand to demonstrate how buggy ACL's are with NFS4 when you DO use acl-2.2.51 with the nfs use flag enabled:

# happy little nfs4 mount here:

> pwd
/mnt/test
> mount | grep /mnt/test
192.168.56.100:/vol/webpages on /mnt/test type nfs4 (rw,addr=192.168.56.100,clientaddr=192.168.56.33)

# Now lets make a folder and give it a default acl

> mkdir foobar
> setfacl -d u:apache:rx foobar

# Lets see what that looks like

> getfacl foobar
# file: foobar
# owner: root
# group: root
user::rwx
group::r-x
other::r-x
default:user::rwx
default:user:apache:r-x
default:group::r-x
default:mask::r-x
default:other::r-x

# Great, default acl is set, now lets try to remove it:

> setfacl -k foobar

# No output, so it worked, right?

> getfacl foobar

# file: foobar
# owner: root
# group: root
user::rwx
group::r-x
other::r-x
default:user::rwx
default:user:apache:r-x
default:group::r-x
default:mask::r-x
default:other::r-x

# NOPE! default acl is still there! What the heck is going on here?

> strace setfacl -k foobar 2>&1 | tail -n2

removexattr("foobar", "system.posix_acl_default") = -1 EOPNOTSUPP (Operation not supported)
exit_group(0)                           = ?
+++ exited with 0 +++

# Nice, posix returns Operation not supported, yet the program exits with 0 anyway! Great job guys,... But wait! there's another acl userland tool we can use to remove acl's,... lets see what happens if we use it....

>  chacl -B foobar
chacl: error removing default acl on "foobar": Operation not supported

# Well, at least chacl returns the proper error,... 
# Lets see, how many bugs can you count here?
Comment 11 Sernin van de Krol 2013-08-27 12:55:46 UTC
The nfs USE flag should be removed, because nfs4 has its own ACL tools.

To work with nfs4 ACLs:
1. disable the nfs USE flag for sys-apps/acl
2. emerge net-fs/nfs4-acl-tools

You will get the tools nfs4_getfacl and nfs4_setfacl to manage ACLs for nfs4 mounts.
Comment 12 John Sennesael 2013-08-27 17:15:01 UTC
> The nfs USE flag should be removed, because nfs4 has its own ACL tools.

Agreed. It would be nice though if the nfs4 tools could be unmasked and any open bugs on it given priority, though. It just pushes people more towards sys-apps/acl causing more confusion. According to the changelog it's been in the tree since 2007, I think 6 years of ~arch is enough? :)
Comment 13 SpanKY gentoo-dev 2013-12-23 07:34:33 UTC
should be all set now in the tree; thanks for the report!

Commit message: Punt the USE=nfs flag as upstream has not updated the patch in years and it no longer applies
http://sources.gentoo.org/sys-apps/acl/acl-2.2.52.ebuild?r1=1.1&r2=1.2