>From Frank Filz <ffilz...@mindspring.com>:

Frank Filz has uploaded a new change for review.

  https://review.gerrithub.io/300030

Change subject: Improve atomic create
......................................................................

Improve atomic create

A user space NFS server has a unique problem in that a create request
(CREATE or OPEN/CREATE) is required to create a file, and set attributes
on the file. Even if the source is a POSIX open() call, an EXCLUSIVE
or EXCLUSIVE_41 create must set the verifier into atime and mtime.

This patch introduces a way for the FSAL to indicate the level of
atomic create and setattrs it provides.

The basic level is no special support, in which case, the fsal_helper.c
function create_helper() will generate a random file name (of the form
nfs_ganesha_XXXXXXXX) and then create the file using that name, only
when everything is complete is the file linked with the requested name.

A second level of support uses O_TMPFILE to create an unnamed file
which has the advantage over the random file name in that if Ganesha
crashes, the temporary file will disappear.

The final level of support is for FSALs that can completely support
an atomic create and setattrs.

For reasons of avoiding regressions, and due to the special nature
of the FSAL, FSAL_RGW claims complete atomic create support.

Change-Id: I666771af7193b92e701c50c4346009613bf60692
Signed-off-by: Frank S. Filz <ffilz...@mindspring.com>
---
M src/FSAL/FSAL_CEPH/handle.c
M src/FSAL/FSAL_GLUSTER/handle.c
M src/FSAL/FSAL_GPFS/file.c
M src/FSAL/FSAL_RGW/handle.c
M src/FSAL/FSAL_RGW/main.c
M src/FSAL/FSAL_VFS/file.c
M src/FSAL/Stackable_FSALs/FSAL_MDCACHE/mdcache_file.c
M src/FSAL/Stackable_FSALs/FSAL_MDCACHE/mdcache_handle.c
M src/FSAL/commonlib.c
M src/FSAL/default_methods.c
M src/FSAL/fsal_helper.c
M src/MainNFSD/nfs_init.c
M src/Protocols/9P/9p_lcreate.c
M src/Protocols/NFS/nfs4_op_open.c
M src/include/FSAL/fsal_commonlib.h
M src/include/fsal.h
M src/include/fsal_api.h
M src/include/fsal_types.h
18 files changed, 736 insertions(+), 269 deletions(-)


  git pull ssh://review.gerrithub.io:29418/ffilz/nfs-ganesha 
refs/changes/30/300030/1
-- 
To view, visit https://review.gerrithub.io/300030
To unsubscribe, visit https://review.gerrithub.io/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I666771af7193b92e701c50c4346009613bf60692
Gerrit-PatchSet: 1
Gerrit-Project: ffilz/nfs-ganesha
Gerrit-Branch: next
Gerrit-Owner: Frank Filz <ffilz...@mindspring.com>

------------------------------------------------------------------------------
The Command Line: Reinvented for Modern Developers
Did the resurgence of CLI tooling catch you by surprise?
Reconnect with the command line and become more productive. 
Learn the new .NET and ASP.NET CLI. Get your free copy!
http://sdm.link/telerik
_______________________________________________
Nfs-ganesha-devel mailing list
Nfs-ganesha-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nfs-ganesha-devel

Reply via email to