From: Matt Benjamin Date: Wed, 19 Jun 2019 18:43:38 +0000 (-0400) Subject: rgw_file: introduce fast S3 Unix stats (immutable) X-Git-Tag: v15.1.0~2345^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F28664%2Fhead;p=ceph.git rgw_file: introduce fast S3 Unix stats (immutable) For objects originating in S3/Swift, it is frequently acceptable to synthesize c/mtime and size stats from meta attributes in the RGW bucket index entry. Synthetic stat behavior is not compatible with mutation of file ownership and permissions via SETATTR. In future, current xattr-based, mutable, Unix stats may be moved to the bucket index. For now, use synthetic stats only when a new option rgw_nfs_s3_fast_attrs is present. Fixes: http://tracker.ceph.com/issues/40456 Signed-off-by: Matt Benjamin --- diff --git a/src/common/legacy_config_opts.h b/src/common/legacy_config_opts.h index 6f18e45c6b2..5156abd00c2 100644 --- a/src/common/legacy_config_opts.h +++ b/src/common/legacy_config_opts.h @@ -1387,6 +1387,10 @@ OPTION(rgw_nfs_max_gc, OPT_INT) /* max gc events per cycle */ OPTION(rgw_nfs_write_completion_interval_s, OPT_INT) /* stateless (V3) * commit * delay */ +OPTION(rgw_nfs_s3_fast_attrs, OPT_BOOL) /* use fast S3 attrs from + * bucket index--currently + * assumes NFS mounts are + * immutable */ OPTION(rgw_zone, OPT_STR) // zone name OPTION(rgw_zone_root_pool, OPT_STR) // pool where zone specific info is stored diff --git a/src/common/options.cc b/src/common/options.cc index d967c934bf6..82c71b3a1f9 100644 --- a/src/common/options.cc +++ b/src/common/options.cc @@ -6063,6 +6063,12 @@ std::vector