nfs-ganesha 1.4
Functions

fsal_rename.c File Reference

#include "fsal.h"
#include "fsal_internal.h"
#include "fsal_convert.h"

Go to the source code of this file.

Functions

fsal_status_t CEPHFSAL_rename (fsal_handle_t *extold_parent, fsal_name_t *old_name, fsal_handle_t *extnew_parent, fsal_name_t *new_name, fsal_op_context_t *extcontext, fsal_attrib_list_t *src_dir_attributes, fsal_attrib_list_t *tgt_dir_attributes)

Function Documentation

fsal_status_t CEPHFSAL_rename ( fsal_handle_t extold_parent,
fsal_name_t old_name,
fsal_handle_t extnew_parent,
fsal_name_t new_name,
fsal_op_context_t extcontext,
fsal_attrib_list_t src_dir_attributes,
fsal_attrib_list_t tgt_dir_attributes 
)

FSAL_rename: Change name and/or parent dir of a filesystem object.

Parameters:
old_parentdir_handle(input): Source parent directory of the object is to be moved/renamed.
p_old_name(input): Pointer to the current name of the object to be moved/renamed.
new_parentdir_handle(input): Target parent directory for the object.
p_new_name(input): Pointer to the new name for the object.
p_context(input): Authentication context for the operation (user,...).
src_dir_attributes(optionnal input/output): Post operation attributes for the source directory. As input, it defines the attributes that the caller wants to retrieve (by positioning flags into this structure) and the output is built considering this input (it fills the structure according to the flags it contains). May be NULL.
tgt_dir_attributes(optionnal input/output): Post operation attributes for the target directory. As input, it defines the attributes that the caller wants to retrieve (by positioning flags into this structure) and the output is built considering this input (it fills the structure according to the flags it contains). May be NULL.
Returns:
Major error codes :
  • ERR_FSAL_NO_ERROR (no error)
  • ERR_FSAL_STALE (a parent directory handle does not address an existing object)
  • ERR_FSAL_NOTDIR (a parent directory handle does not address a directory)
  • ERR_FSAL_NOENT (the object designated by p_old_name does not exist)
  • ERR_FSAL_NOTEMPTY (the target object is a non empty directory)
  • ERR_FSAL_XDEV (tried to move an object across different filesystems)
  • ERR_FSAL_FAULT (a NULL pointer was passed as mandatory argument)
  • Other error codes can be returnoed : ERR_FSAL_ACCESS, ERR_FSAL_IO, ...

Definition at line 84 of file FSAL_CEPH/fsal_rename.c.