From c705b679fbe41aa9ac4486ebf46d3b2ae95d1628 Mon Sep 17 00:00:00 2001 From: Shehjar Tikoo Date: Tue, 18 May 2010 01:37:42 +0000 Subject: nfs: Introduce trusted-write and trusted-sync options Introduces two new options: 1. nfs3.*.trusted-write: Forces UNSTABLE writes to return STABLE to NFS clients to prevent the clients from sending a COMMIT. STABLE writes are still handled in a sync manner and so are COMMITs if they're sent at all. 2. nfs3.*.trusted-sync: Forces all WRITEs and COMMITs to return STABLE return flags to NFS clients to avoid the overhead of STABLE writes, and COMMITs that follow UNSTABLE writes. This includes the trusted-write functionality. In addition to the trusted-write, it also writes STABLE writes in an UNSTABLE manner. Both violate the NFS protocol but allow better write perf in most configurations. Use with caution. Signed-off-by: Shehjar Tikoo Signed-off-by: Anand V. Avati BUG: 924 (Slow NFS synchronous writes) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=924 --- xlators/nfs/server/src/nfs3.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'xlators/nfs/server/src/nfs3.h') diff --git a/xlators/nfs/server/src/nfs3.h b/xlators/nfs/server/src/nfs3.h index bb5fbb750..ccdad4477 100644 --- a/xlators/nfs/server/src/nfs3.h +++ b/xlators/nfs/server/src/nfs3.h @@ -84,6 +84,8 @@ struct nfs3_fd_entry { struct nfs3_export { xlator_t *subvol; int access; + int trusted_sync; + int trusted_write; }; #define GF_NFS3_DEFAULT_VOLACCESS (GF_NFS3_VOLACCESS_RW) -- cgit