From 64e7e3a4b9a1e1d52d21aebb49f77e3cd9fde24b Mon Sep 17 00:00:00 2001 From: Daniel Gryniewicz Date: Thu, 18 Sep 2025 12:22:21 -0400 Subject: [PATCH] RGW - POSIXDriver - Cleanup vstart - Disentangle POSIX from DBStore config in vstart - Give POSIX it's own config for userdb location Signed-off-by: Daniel Gryniewicz --- src/common/options/rgw.yaml.in | 7 ++++ src/rgw/driver/posix/rgw_sal_posix.h | 2 +- src/vstart.sh | 58 +++++++++++++++------------- 3 files changed, 40 insertions(+), 27 deletions(-) diff --git a/src/common/options/rgw.yaml.in b/src/common/options/rgw.yaml.in index 6ab18332f5f..8482792be51 100644 --- a/src/common/options/rgw.yaml.in +++ b/src/common/options/rgw.yaml.in @@ -4124,6 +4124,13 @@ options: default: /tmp/rgw_posix_driver services: - rgw +- name: rgw_posix_userdb_dir + type: str + level: advanced + desc: path for the directory for storing the User db + default: /var/lib/ceph/radosgw + services: + - rgw - name: rgw_posix_database_root type: str level: advanced diff --git a/src/rgw/driver/posix/rgw_sal_posix.h b/src/rgw/driver/posix/rgw_sal_posix.h index fe664574d2d..3be73187ca6 100644 --- a/src/rgw/driver/posix/rgw_sal_posix.h +++ b/src/rgw/driver/posix/rgw_sal_posix.h @@ -481,7 +481,7 @@ public: POSIXDriver(CephContext *_cct) : StoreDriver(), cct(_cct), zone(this) { const static std::string tenant = "default_ns"; - const auto& db_path = g_conf().get_val("dbstore_db_dir"); + const auto& db_path = g_conf().get_val("rgw_posix_userdb_dir"); const auto& db_name = g_conf().get_val("dbstore_db_name_prefix") + "-" + tenant; auto db_full_path = std::filesystem::path(db_path) / db_name; diff --git a/src/vstart.sh b/src/vstart.sh index 5f2839f033a..b4738dff183 100755 --- a/src/vstart.sh +++ b/src/vstart.sh @@ -796,26 +796,6 @@ done } -do_rgw_dbstore_conf() { - if [ $CEPH_NUM_RGW -gt 1 ]; then - echo "dbstore is not distributed so only works with CEPH_NUM_RGW=1" - exit 1 - fi - - if [ "$new" -eq 1 ]; then - prun rm -rf "$CEPH_DEV_DIR/rgw/dbstore" - fi - - prun mkdir -p "$CEPH_DEV_DIR/rgw/dbstore" - wconf <