+++ This bug was initially created as a clone of Bug #1452961 +++ Description of problem: The Linux llistxattr() system call and the FreeBSD extattr_list_link() system call both get the list of xattrs, but in different format (check the manpages): Linux: attr<\0>attr<\0> FreeBSD: <attr_len>attr<attr_len>attr But in the caller sys_llistxattr and sys_flistxattr do not take the format difference into account. This patch is based on v3.9.0, it fixes the problem by introducing a new function extattr_list_reshape to reshape the FreeBSD list format into Linux's. This patch is authored by Iblis Lin <iblis.edu.tw> and tested by Pellaeon Lin <pellaeon> For your reference, here's the Gist comparing GDB output of volume process with and without patch: https://gist.github.com/pellaeon/bfa9b094e11b47a88bf51f5aa73b9a6d --- Additional comment from on 2017-05-21 05:12:02 EDT --- This patch fixes the problem described by: https://bugzilla.redhat.com/show_bug.cgi?id=1181500#c5 But I'm not sure it'll solve the bug 1181500 . --- Additional comment from Pranith Kumar K on 2017-07-12 23:00:01 EDT --- (In reply to nfsmwlin from comment #1) > This patch fixes the problem described by: > https://bugzilla.redhat.com/show_bug.cgi?id=1181500#c5 > > But I'm not sure it'll solve the bug 1181500 . hey, this is good patch. Do you want to send the patch on review.gluster.org?
REVIEW: https://review.gluster.org/17917 (posix: fix Bug 1452961 incorrect xattr list handling on FreeBSD) posted (#3) for review on master by Anonymous Coward
REVIEW: https://review.gluster.org/17917 (posix: fix incorrect xattr list handling on FreeBSD) posted (#4) for review on master by jiffin tony Thottan (jthottan)
REVIEW: https://review.gluster.org/17917 (posix: fix incorrect xattr list handling on FreeBSD) posted (#5) for review on master by jiffin tony Thottan (jthottan)
REVIEW: https://review.gluster.org/17917 (posix: fix incorrect xattr list handling on FreeBSD) posted (#6) for review on master by jiffin tony Thottan (jthottan)
COMMIT: https://review.gluster.org/17917 committed in master by Amar Tumballi (amarts) ------ commit bf7b0b60b1710b19561a2f7c79c3be4d09842b2c Author: Iblis Lin <iblis.edu.tw> Date: Mon Jul 31 11:25:07 2017 +0800 posix: fix incorrect xattr list handling on FreeBSD Change-Id: I5be157259f0b665640aaa1eda68063bb19fd7b3d BUG: 1484246 Signed-off-by: Pellaeon Lin <nfsmwlin> Signed-off-by: Jiffin Tony Thottan <jthottan> Reviewed-on: https://review.gluster.org/17917 Smoke: Gluster Build System <jenkins.org> Reviewed-by: Amar Tumballi <amarts> Reviewed-by: Niels de Vos <ndevos> CentOS-regression: Gluster Build System <jenkins.org>
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-3.13.0, please open a new bug report. glusterfs-3.13.0 has been announced on the Gluster mailinglists [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution. [1] http://lists.gluster.org/pipermail/announce/2017-December/000087.html [2] https://www.gluster.org/pipermail/gluster-users/