Change in ...nfs-ganesha[next]: testing: do not merge
by Kaleb KEITHLEY (GerritHub)
Kaleb KEITHLEY has uploaded this change for review. ( https://review.gerrithub.io/c/ffilz/nfs-ganesha/+/489134 )
Change subject: testing: do not merge
......................................................................
testing: do not merge
testing new iozone_vfs and iozone_vfs_minmdcache tests in centos-ci
Change-Id: Ia7a700a50edfa41673a6c64eaeca429d1168bbca
Signed-off-by: Kaleb S. KEITHLEY <kkeithle(a)redhat.com>
---
M src/MainNFSD/nfs_main.c
1 file changed, 2 insertions(+), 0 deletions(-)
git pull ssh://review.gerrithub.io:29418/ffilz/nfs-ganesha refs/changes/34/489134/1
--
To view, visit https://review.gerrithub.io/c/ffilz/nfs-ganesha/+/489134
To unsubscribe, or for help writing mail filters, visit https://review.gerrithub.io/settings
Gerrit-Project: ffilz/nfs-ganesha
Gerrit-Branch: next
Gerrit-Change-Id: Ia7a700a50edfa41673a6c64eaeca429d1168bbca
Gerrit-Change-Number: 489134
Gerrit-PatchSet: 1
Gerrit-Owner: Kaleb KEITHLEY <kaleb(a)redhat.com>
Gerrit-MessageType: newchange
4 years, 8 months
Change in ...nfs-ganesha[next]: Breaking rename of libfsalproxy => libfsalproxy_v4.
by Solomon Boulos (GerritHub)
Solomon Boulos has uploaded this change for review. ( https://review.gerrithub.io/c/ffilz/nfs-ganesha/+/488937 )
Change subject: Breaking rename of libfsalproxy => libfsalproxy_v4.
......................................................................
Breaking rename of libfsalproxy => libfsalproxy_v4.
dang@ suggested that since V4 is a while away, it would be better to rip
the bandaid now on telling people to update their configs. Keeping this
as a separate change hopefully makes it easier for people to patch the
other proxy changes into their backported tree if needed without forcing
a config update.
Change-Id: I08f6e4dc9355612e2560fd33fab1d23ae51eb1a0
Signed-off-by: Solomon Boulos <boulos(a)google.com>
---
M src/FSAL/FSAL_PROXY_V4/CMakeLists.txt
M src/FSAL/FSAL_PROXY_V4/main.c
R src/doc/man/ganesha-proxy-v4-config.rst
M src/nfs-ganesha.spec-in.cmake
4 files changed, 15 insertions(+), 38 deletions(-)
git pull ssh://review.gerrithub.io:29418/ffilz/nfs-ganesha refs/changes/37/488937/1
--
To view, visit https://review.gerrithub.io/c/ffilz/nfs-ganesha/+/488937
To unsubscribe, or for help writing mail filters, visit https://review.gerrithub.io/settings
Gerrit-Project: ffilz/nfs-ganesha
Gerrit-Branch: next
Gerrit-Change-Id: I08f6e4dc9355612e2560fd33fab1d23ae51eb1a0
Gerrit-Change-Number: 488937
Gerrit-PatchSet: 1
Gerrit-Owner: Solomon Boulos <boulos(a)google.com>
Gerrit-MessageType: newchange
4 years, 8 months
READDIR slowdown while write is in progress.
by Pradeep Thomas
If a client starts writing a large file, then the READDIR from that directory seems to be stuck. Debugging further, it appears to be caused by a lock contention between FSAL merge (vfs_merge()) and write or commit FSAL functions.
- Since write started first, OPEN would have created a new MDCACHE entry.
- As part of READDIR, MDCACHE tries to create a new entry for the same file, so mdcache_new_entry() will reach obj_ops->merge().
This seems to get stuck trying to get the obj_lock in write mode.
- Since client is sending multiple writes and commits, the readdir thread seems to be stuck until it can get the write lock in vfs_merge().
Can be reproduced by the following commands (latest Ganesha, VFS FSAL):
Let's say, /gsh4 is the mount point
- mkdir /gsh4/dir.1
- touch /gsh4/dir.1/file.{1..100}
- dd if=/dev/zero of=/gsh4/dir.1/largefile bs=1M count=100000 &
- ls /gsh4/dir.1
Note that any other client doing a READDIR will also be slow.
Is there a way this path can be optimized? Wouldn't share_counters be zero in readdir path (meaning there isn't anything to merge)?
Thanks,
Pradeep
4 years, 8 months
Announce Push of V4-dev.11
by Frank Filz
Branch next
Tag:V4-dev.11
Merge Highlights
* client_mgr: fix free of static data
* nfs4 readdir: fix use of NFS3 errors in NFS4 code
* doc: clarify the User_Id setting in the sample config
* Update dupreq after svc_sendreply failure
* Make sure no_cleanup is set under the state_lock
* Reduce log level for rpc.statd communication failures
* Ensure op_ctx is set when releasing an export
* Fix crash in PROXY_V4 readdir.
* Introduce FSAL_PROXY_V3 and rename FSAL_PROXY to FSAL_PROXY_V4
Signed-off-by: Frank S. Filz <ffilzlnx(a)mindspring.com>
Contents:
a6c5f6c Frank S. Filz V4-dev.11
d6ef4a3 Solomon Boulos Initial NFSv3 proxying FSAL.
f4ddbc8 Solomon Boulos Rename the V4 proxy names from pxy_ to proxyv4.
691cfa1 Solomon Boulos Rename FSAL_PROXY => FSAL_PROXY_V4.
06ddb5a Solomon Boulos Fix crash in PROXY_V4 readdir.
15bc66f Daniel Gryniewicz Ensure op_ctx is set when releasing an export
02c916e Malahal Naineni Reduce log level for rpc.statd communication
failures
d0d352e Malahal Naineni Make sure no_cleanup is set under the state_lock
97d04b3 Malahal Naineni Update dupreq after svc_sendreply failure
9260c43 Jeff Layton doc: clarify the User_Id setting in the sample config
0f89bb3 Dominique Martinet nfs4 readdir: fix use of NFS3 errors in NFS4 code
418ecfe Dominique Martinet client_mgr: fix free of static data
4 years, 8 months
Crash in dupreq
by katcherw@gmail.com
We saw a crash in version 2.8.2 running an iozone crash:
Program terminated with signal 11, Segmentation fault.
#0 0x00007ff028dce240 in atomic_sub_uint32_t (var=0x104, sub=1) at /usr/src/debug/nfs-ganesha-2.8.2/include/abstract_atomic.h:384
384 return __atomic_sub_fetch(var, sub, __ATOMIC_SEQ_CST);
Missing separate debuginfos, use: debuginfo-install bzip2-libs-1.0.6-12.el7.x86_64 dbus-libs-1.11.16-1.fc26.x86_64 elfutils-libelf-0.158-3.el7.x86_64 elfutils-libs-0.158-3.el7.x86_64 glibc-2.17-55.el7.x86_64 gssproxy-0.3.0-9.el7.x86_64 keyutils-libs-1.5.8-3.el7.x86_64 krb5-libs-1.15.1-8.el7.x86_64 libacl-2.2.51-12.el7.x86_64 libattr-2.4.46-12.el7.x86_64 libblkid-2.23.2-16.el7.x86_64 libcap-2.22-8.el7.x86_64 libcom_err-1.42.9-10.el7.x86_64 libgcrypt-1.5.3-4.el7.x86_64 libgpg-error-1.12-3.el7.x86_64 libnfsidmap-0.25-9.el7.x86_64 libselinux-2.5-11.el7.x86_64 libuuid-2.23.2-16.el7.x86_64 libwbclient-4.8.3-4.el7.x86_64 pcre-8.32-12.el7.x86_64 samba-client-libs-4.8.3-4.el7.x86_64 samba-winbind-modules-4.8.3-4.el7.x86_64 sssd-client-1.11.2-65.el7.x86_64 systemd-libs-219-42.el7_4.1.x86_64 userspace-rcu-0.7.16-1.el7.x86_64 xz-libs-5.1.2-8alpha.el7.x86_64 zlib-1.2.7-13.el7.x86_64
(gdb) bt
#0 0x00007ff028dce240 in atomic_sub_uint32_t (var=0x104, sub=1) at /usr/src/debug/nfs-ganesha-2.8.2/include/abstract_atomic.h:384
#1 0x00007ff028dce265 in atomic_dec_uint32_t (var=0x104) at /usr/src/debug/nfs-ganesha-2.8.2/include/abstract_atomic.h:405
#2 0x00007ff028dd1b65 in dupreq_entry_put (dv=0x0) at /usr/src/debug/nfs-ganesha-2.8.2/RPCAL/nfs_dupreq.c:912
#3 0x00007ff028dd4630 in nfs_dupreq_rele (req=0x7fec44a269f0, func=0x7ff029159d60 <nfs3_func_desc+672>) at /usr/src/debug/nfs-ganesha-2.8.2/RPCAL/nfs_dupreq.c:1382
#4 0x00007ff028d74bc5 in free_args (reqdata=0x7fec44a269f0) at /usr/src/debug/nfs-ganesha-2.8.2/MainNFSD/nfs_worker_thread.c:693
#5 0x00007ff028d77783 in nfs_rpc_process_request (reqdata=0x7fec44a269f0) at /usr/src/debug/nfs-ganesha-2.8.2/MainNFSD/nfs_worker_thread.c:1509
#6 0x00007ff028d77a74 in nfs_rpc_valid_NFS (req=0x7fec44a269f0) at /usr/src/debug/nfs-ganesha-2.8.2/MainNFSD/nfs_worker_thread.c:1601
#7 0x00007ff028b2632d in svc_vc_decode (req=0x7fec44a269f0) at /usr/src/debug/nfs-ganesha-2.8.2/libntirpc/src/svc_vc.c:829
#8 0x00007ff028b227bf in svc_request (xprt=0x7fee0c202ad0, xdrs=0x7fec3c987a70) at /usr/src/debug/nfs-ganesha-2.8.2/libntirpc/src/svc_rqst.c:793
#9 0x00007ff028b2623e in svc_vc_recv (xprt=0x7fee0c202ad0) at /usr/src/debug/nfs-ganesha-2.8.2/libntirpc/src/svc_vc.c:802
#10 0x00007ff028b22740 in svc_rqst_xprt_task (wpe=0x7fee0c202cf0) at /usr/src/debug/nfs-ganesha-2.8.2/libntirpc/src/svc_rqst.c:774
#11 0x00007ff028b23048 in svc_rqst_epoll_loop (wpe=0x108d570) at /usr/src/debug/nfs-ganesha-2.8.2/libntirpc/src/svc_rqst.c:1089
#12 0x00007ff028b2baff in work_pool_thread (arg=0x7fed44052070) at /usr/src/debug/nfs-ganesha-2.8.2/libntirpc/src/work_pool.c:184
#13 0x00007ff0270c8df3 in start_thread () from /lib64/libpthread.so.0
#14 0x00007ff0267cd3dd in clone () from /lib64/libc.so.6
(gdb) frame 5
#5 0x00007ff028d77783 in nfs_rpc_process_request (reqdata=0x7fec44a269f0) at /usr/src/debug/nfs-ganesha-2.8.2/MainNFSD/nfs_worker_thread.c:1509
1509 free_args(reqdata);
(gdb) p *reqdata
$2 = {
svc = {
rq_xprt = 0x7fee0c202ad0,
rq_clntname = 0x0,
rq_svcname = 0x0,
rq_xdrs = 0x7fec3c987a70,
rq_u1 = 0x0,
rq_u2 = 0x0,
rq_cksum = 14781944753697519387,
rq_auth = 0x7ff028d45cd0 <svc_auth_none>,
rq_ap1 = 0x0,
rq_ap2 = 0x0,
...
Notice rq_u1 == 0. nfs_rpc_process_request is calling free_args which is calling nfs_dupreq_rele. There is a comment at the beginning of nfs_dupreq_rele:
* We assert req->rq_u1 now points to the corresponding duplicate request
* cache entry (dv).
But this assumption doesn't seem to be true, and eventually this will be dereferenced leading to a crash. We're trying to reproduce the problem with NIV_FULL_DEBUG.
Has anyone seen this problem before, or know what would cause rq_u1 to be 0? Should there be a check for NULL in nfs_dupreq_rele in addition to DUPREQ_NOCACHE?
Bill
4 years, 8 months
Change in ...nfs-ganesha[next]: Initial NFSv3 proxying FSAL.
by Solomon Boulos (GerritHub)
Solomon Boulos has uploaded this change for review. ( https://review.gerrithub.io/c/ffilz/nfs-ganesha/+/488664 )
Change subject: Initial NFSv3 proxying FSAL.
......................................................................
Initial NFSv3 proxying FSAL.
[As requested, merging all of these commits into one]
This patch series adds an NFSv3 proxy following the example from the
NFSv4 proxy that Ganesha already has. I saw a few people ask for this on
the list, and it seemed easy enough to do. I believe the implementation
is semi-reasonable (e.g., it passes the cthon testsuite, including
locking) but definitely doesn't do things particularly efficiently. This
is my first foray into both Ganesha and NFS, so apologies for obvious
errors.
Note that I explicitly chose to make this a separate FSAL rather than
intermingle it with the V4 proxy. While there's probably some
opportunity for sharing, it seemed easier to confine each to their own
directory, particularly since a V3 server can't handle V4 clients
correctly (you could translate some things to let it "kind of work", but
that seems risky). As future work, someone could imagine probing a
backend and switching between the two FSALs.
Change-Id: I45926761389ef61af281f7ba0f7e643fd32b4ee5
Signed-off-by: Solomon Boulos <boulos(a)google.com>
Support readahead.
Change-Id: Icf2270ce625e15bf3aa9a00d3b25cfebdbb1fbc1
Signed-off-by: Solomon Boulos <boulos(a)google.com>
---
M src/CMakeLists.txt
M src/FSAL/CMakeLists.txt
A src/FSAL/FSAL_PROXY_V3/CMakeLists.txt
A src/FSAL/FSAL_PROXY_V3/main.c
A src/FSAL/FSAL_PROXY_V3/nlm.c
A src/FSAL/FSAL_PROXY_V3/proxyv3_fsal_methods.h
A src/FSAL/FSAL_PROXY_V3/rpc.c
A src/FSAL/FSAL_PROXY_V3/utils.c
A src/config_samples/proxy_v3.conf
M src/doc/man/ganesha-config.rst
A src/doc/man/ganesha-proxy-v3-config.rst
11 files changed, 4,879 insertions(+), 0 deletions(-)
git pull ssh://review.gerrithub.io:29418/ffilz/nfs-ganesha refs/changes/64/488664/1
--
To view, visit https://review.gerrithub.io/c/ffilz/nfs-ganesha/+/488664
To unsubscribe, or for help writing mail filters, visit https://review.gerrithub.io/settings
Gerrit-Project: ffilz/nfs-ganesha
Gerrit-Branch: next
Gerrit-Change-Id: Icf2270ce625e15bf3aa9a00d3b25cfebdbb1fbc1
Gerrit-Change-Number: 488664
Gerrit-PatchSet: 1
Gerrit-Owner: Solomon Boulos <boulos(a)google.com>
Gerrit-MessageType: newchange
4 years, 8 months
Change in ...nfs-ganesha[next]: Fix crash in PROXY_V4 readdir.
by Solomon Boulos (GerritHub)
Solomon Boulos has uploaded this change for review. ( https://review.gerrithub.io/c/ffilz/nfs-ganesha/+/488663 )
Change subject: Fix crash in PROXY_V4 readdir.
......................................................................
Fix crash in PROXY_V4 readdir.
The change in f6edd32b5f7 added a new optimized path for readdir4
encode/decode, but the NFS v4 proxy code wasn't properly clearing the
result struct. This change memset(0)s the result before using it to
avoid any mishaps. cthon04 now runs just fine.
Change-Id: Iab2372818958a8390ded1b83b46073248a15e6d9
Signed-off-by: Solomon Boulos <boulos(a)google.com>
---
M src/FSAL/FSAL_PROXY_V4/handle.c
1 file changed, 9 insertions(+), 2 deletions(-)
git pull ssh://review.gerrithub.io:29418/ffilz/nfs-ganesha refs/changes/63/488663/1
--
To view, visit https://review.gerrithub.io/c/ffilz/nfs-ganesha/+/488663
To unsubscribe, or for help writing mail filters, visit https://review.gerrithub.io/settings
Gerrit-Project: ffilz/nfs-ganesha
Gerrit-Branch: next
Gerrit-Change-Id: Iab2372818958a8390ded1b83b46073248a15e6d9
Gerrit-Change-Number: 488663
Gerrit-PatchSet: 1
Gerrit-Owner: Solomon Boulos <boulos(a)google.com>
Gerrit-MessageType: newchange
4 years, 8 months