From a229ee1c8cdf8e0ac1abaeb60cabe6ab08f60546 Mon Sep 17 00:00:00 2001 From: Raghavendra Gowdappa Date: Tue, 29 Jan 2019 08:05:07 +0530 Subject: mount/fuse: expose auto-invalidation as a mount option Auto invalidation is necessary when same (meta)data is shared/access across multiple mounts. However, if (meta)data is not shared, all relevant I/O goes through the cache of single mount and hence is coherent with (meta)data on bricks always. So, fuse-auto-invalidation can be disabled for this case which gives a huge performance boost for workloads that write data and then immediately read the data they just wrote. From glusterfs --help, --auto-invalidation[=BOOL] controls whether fuse-kernel can auto-invalidate attribute, dentry and page-cache. Disable this only if same files/directories are not accessed across two different mounts concurrently [default: "on"] Details on how disabling auto-invalidation helped to reduce pgbench init times can be found at [1]. Time taken for pgbench init of scale 8000 was 8340s. That will be an improvement of 86% (59280s vs 8340s) with auto-invalidations turned off along with other optimizations. Just disabling auto-invalidation contributed 56% improvement by reducing the total time taken by 33260s. [1] https://www.spinics.net/lists/gluster-devel/msg25907.html Change-Id: I0ed730dba9064bd9c576ad1800170a21e100e1ce Signed-off-by: Raghavendra Gowdappa updates: bz#1664934 --- doc/glusterfs.8 | 5 +++++ doc/glusterfsd.8 | 5 +++++ doc/mount.glusterfs.8 | 5 +++++ 3 files changed, 15 insertions(+) (limited to 'doc') diff --git a/doc/glusterfs.8 b/doc/glusterfs.8 index 0538c00e570..e36bd6fbcfe 100644 --- a/doc/glusterfs.8 +++ b/doc/glusterfs.8 @@ -139,6 +139,11 @@ Enable fuse in-kernel writeback cache. \fB\-\-negative\-timeout=SECONDS\fR Set negative timeout to SECONDS in fuse kernel module (the default is 0). .TP +\fB\-\-auto\-invalidation=BOOL\fR +controls whether fuse-kernel can auto-invalidate attribute, dentry and +page-cache. Disable this only if same files/directories are not +accessed across two different mounts concurrently [default: on]. +.TP \fB\-\-volfile-check\fR Enable strict volume file checking. diff --git a/doc/glusterfsd.8 b/doc/glusterfsd.8 index aa6327c2c73..bc1de2a8c80 100644 --- a/doc/glusterfsd.8 +++ b/doc/glusterfsd.8 @@ -107,6 +107,11 @@ Enable/Disable direct-io mode in fuse module [default: enable] .TP \fB\-\-resolve-gids\fR Resolve all auxiliary groups in fuse translator (max 32 otherwise) +.TP +\fB\-\-auto\-invalidation=BOOL\fR +controls whether fuse-kernel can auto-invalidate attribute, dentry and +page-cache. Disable this only if same files/directories are not +accessed across two different mounts concurrently [default: on] .SS "Miscellaneous Options" .PP diff --git a/doc/mount.glusterfs.8 b/doc/mount.glusterfs.8 index 902b0c1ee5c..d3c3533e284 100644 --- a/doc/mount.glusterfs.8 +++ b/doc/mount.glusterfs.8 @@ -146,6 +146,11 @@ Enable fuse in-kernel writeback cache [default: off] .TP \fBattr\-times\-granularity=\fRNS Declare supported granularity of file attribute [default: 0] +.TP +\fBauto\-invalidation=\fRBOOL +controls whether fuse-kernel can auto-invalidate attribute, dentry and +page-cache. Disable this only if same files/directories are not +accessed across two different mounts concurrently [default: on] .PP .SH FILES .TP -- cgit