New dbus stats method GetNFSIO

Adds a bulk method to retrieve I/O stats of all exports and all protocol versions.

Signed-off-by: Haubrich <haubrich@de.ibm.com>
Acked-by: Malahal Naineni <malahal@us.ibm.com>
Fix chkconfig pid file to use the same file passed to ganesha

Signed-off-by: Allison Henderson <achender@vnet.linux.ibm.com>
Spec file cleanups

- Merge in some dependencies from the Fedora/RedHat spec file
- Set the extraversion, if it exists, on the RPMs

Signed-off-by: Daniel Gryniewicz <dang@cohortfs.com>
Initialize sub_nodes glist in the root config node.

An empty config file will result in NULL sub_nodes list rather an an
empty sub_nodes list resulting in a segfault later.

Also added a check to make sure we don't add a NULL entry to sub_nodes
list when all blocks are empty.

Signed-off-by: Malahal Naineni <malahal@us.ibm.com>
Acked-by: Frank S. Filz <ffilzlnx@mindspring.com>
Merge remote-tracking branch 'haubrich/stats-work-04' into next

Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Merge remote-tracking branch 'dang/spec-file' into next

Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Merge remote-tracking branch 'malahal/lex-list' into next

Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Merge remote-tracking branch 'remotes/achender/fix_checkconfgv2' into next

Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Don't use args from stack when calling async op.

Signed-off-by: Marc Eshel <eshel@us.ibm.com>
Add option to delegate grace recovery to the FSAL.

Signed-off-by: Marc Eshel <eshel@us.ibm.com>
Fix user_date_fmt and time_date_fmt resulting in null time strings bug.

Fix bug: Log using user_time_fmt resulted in null time strings.  This is
because user_date_fmt_ and time_date_fmt are passed as fields to a
structure, and not as global statics.  Use the structure fields, and get
rid of the statics which should no longer be used.

Config file fragment for testing purposes.
	LOG {
	 Format {
	  date_format = none;
	  time_format = user_defined;
	  user_time_format = "%s";
	 }
	}

Signed-off-by: Marcus Watts <mdw@linuxbox.com>
Merge remote-tracking branch 'linuxbox2/config_user_date_fmt_fix' into next

Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Merge remote-tracking branch 'marc/grace-opt' into next

Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
V2.2-dev-17

Signed-off-by: Frank S. Filz <ffilzlnx@mindspring.com>
Update Ceph FSAL configuration to match others.

* better error returns and diagnostics
* add some configuration stubs
* cosmetic: reformatting, comments

There are some ceph functions here that are not present in any release
version of ceph.  This marks them "if 0" for future work.  This isn't
useful without pnfs / ds, which this code doesn't (yet) support.

Revise the configuration logic to better match the pattern used
in all the other fsals.  No more silly cases in fs_supports()!

Also: create files, symlinks, and directories with the permissions
actually requested, and support "fs_umask" to reduce those permissions
like the other fsals do.

Signed-off-by: William Allen Simpson <bill@cohortfs.com>
Signed-off-by: Marcus Watts <mdw@cohortfs.com>
handle empty and missing configuration file.

 + without immediately dying
 * correctly clear config_file_t to NULL
 * reduce minor parse errors from Crit to Warn
 * fix several incorrect err_types
 * gracefully return after missing sub-nodes and trees
 * for LOG block, allow empty as well as harmless!

Signed-off-by: William Allen Simpson <bill@cohortfs.com>
Acked-by: Jim Lieb <lieb@sea-troll.net>
Consolidate FSAL initiation into fsal_manager

In order to have a DS {} block with a FSAL {} block in it,
reshuffle some of the FSAL functions that were in various
files into include/fsal.h and FSAL/fsal_manager.c, as
fsal_load_init() is the only caller of load_fsal() there.

Merge name length testing into fsal_load_init().

Rename struct fsal_args to match struct subfsal_args.
Reorder struct subfsal_args to match struct fsal_args.

Signed-off-by: William Allen Simpson <bill@cohortfs.com>
Acked-by: Jim Lieb <lieb@sea-troll.net>
Strict hierarchy of sal_data.h and sal_functions.h

* sal_functions.h is now only called from .c
* Move forward declarations above #includes in sal_data.h,
  to improve circular dependency processing

+ Replace/merge state_status_t with g_u_s_t

- Remove unused nfs_exports.h from sal_functions.h
- Remove nfs_proto_functions.h from sal_data.h,
  fixing circular dependency!
- Do not include 9p.h for one typedef in sal_data.h,
  fixing circular dependency!

Signed-off-by: William Allen Simpson <bill@cohortfs.com>
Refactor cache_inode.h forward declarations

* Move some forward declarations above #includes,
  and resolve forward declarations near end of file,
  to improve circular dependency processing
+ Move entry_export_map after typedef struct cache_entry_t
  to avoid redundant forward declaration

+ Replace/merge cache_inode_status_t with g_u_s_t

Signed-off-by: William Allen Simpson <bill@cohortfs.com>
Move most definitions from fsal.h to fsal_types.h

Signed-off-by: William Allen Simpson <bill@cohortfs.com>