Project

General

Profile

Actions

Bug #77544

closed
FK NM

Dashboard/RGW: Stale RGW user/account metadata cache in mgr after delete and recreate

Bug #77544: Dashboard/RGW: Stale RGW user/account metadata cache in mgr after delete and recreate

Added by farhad khedriyan 6 months ago. Updated 3 months ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
Backend
Target version:
Due date:
% Done:

0%

Source:
Backport:
tentacle,umbrella
Regression:
No
Severity:
3 - minor
Reviewed:
06/16/2026
Affected Versions:
ceph-qa-suite:
Pull request ID:
Tags (freeform):
Fixed In:
v21.3.0-1005-gef47d68738
Released In:
Upkeep Timestamp:
2026-08-27T18:40:46+00:00

Description

Description
There is a reproducible issue where Ceph Dashboard (via ceph-mgr) fails to authenticate against RGW after an RGW account/user is deleted and then recreated with the same name/tenant. It appears that the Dashboard or the underlying RGW client in ceph-mgr caches a "negative entry" for the Access Key and does not invalidate it upon recreation of the user.also see this bug in version 20.2.2

  • Environment*
    - Ceph Version: ceph version 20.2.1 (6a49aff47758778a5f5951e731d437c317f72fb2) tentacle (stable)
    - Deployment: cephadm
    - RGW Setup: Multi-site enabled (single zonegroup/zone in this case) behind HAProxy.
  • Steps to Reproduce*
    1. Create an RGW Account and User (e.g., tenant: `bobo`, user: `pepe`).
    2. Delete the RGW user and account (including all buckets).
    3. Recreate the RGW account and user with the exact same names.
    4. Attempt to create a bucket through the Ceph Dashboard using the newly created account.
  • Actual Result*
    The bucket creation fails with `403 Forbidden`.
    Dashboard logs show: `RGW REST API failed request with status code 403. Code: InvalidAccessKeyId`.

RGW debug logs (debug_rgw 20) show:
`cache get: name=vanak.rgw.meta+users.keys+[ACCESS_KEY] : hit (negative entry)`
`error reading user info, uid=[ACCESS_KEY] can't authenticate`

  • Expected Result*
    The Dashboard should be able to create the bucket immediately after user recreation without manual intervention.

    Workaround
    Restarting the MGR service (`ceph orch restart mgr`) resolves the issue immediately, confirming the stale state is held within the mgr process.

  • Additional Info*
    It seems the RGW client/metadata cache in ceph-mgr is not aware of the external changes or fails to invalidate the negative lookup result when the user is recreated.
  • dashboard log*
    
    debug 2026-06-15T09:53:23.638+0000 7f85eeba0640  0 [dashboard ERROR rest_client] RGW REST API failed PUT req status: 403
    debug 2026-06-15T09:53:23.638+0000 7f85eeba0640  0 [dashboard ERROR exception] Dashboard Exception
    Traceback (most recent call last):
      File "/usr/share/ceph/mgr/dashboard/controllers/rgw.py", line 635, in create
        result = rgw_client.create_bucket(bucket, zonegroup,
      File "/usr/share/ceph/mgr/dashboard/rest_client.py", line 538, in func_wrapper
        return func(
      File "/usr/share/ceph/mgr/dashboard/services/rgw_client.py", line 559, in create_bucket
        return request(data=data, headers=headers)
      File "/usr/share/ceph/mgr/dashboard/rest_client.py", line 324, in __call__
        resp = self.rest_client.do_request(method, self._gen_path(), params,
      File "/usr/share/ceph/mgr/dashboard/rest_client.py", line 422, in do_request
        raise RequestException(
    dashboard.rest_client.RequestException: RGW REST API failed request with status code 403
    (b'{"Code":"InvalidAccessKeyId","Message":"","RequestId":"tx00000ea549eca89bb48'
     b'88-006a2fcb93-120358203-vanak","HostId":"120358203-vanak-tehran"}')
    
    During handling of the above exception, another exception occurred:
    
    Traceback (most recent call last):
      File "/usr/share/ceph/mgr/dashboard/services/exception.py", line 47, in dashboard_exception_handler
        return handler(*args, **kwargs)
      File "/lib/python3.9/site-packages/cherrypy/_cpdispatch.py", line 54, in __call__
        return self.callable(*self.args, **self.kwargs)
      File "/usr/share/ceph/mgr/dashboard/controllers/_base_controller.py", line 264, in inner
        ret = func(*args, **kwargs)
      File "/usr/share/ceph/mgr/dashboard/controllers/_rest_controller.py", line 193, in wrapper
        return func(*vpath, **params)
      File "/usr/share/ceph/mgr/dashboard/controllers/rgw.py", line 659, in create
        raise DashboardException(e, http_status_code=500, component='rgw')
    dashboard.exceptions.DashboardException: RGW REST API failed request with status code 403
    (b'{"Code":"InvalidAccessKeyId","Message":"","RequestId":"tx00000ea549eca89bb48'
     b'88-006a2fcb93-120358203-vanak","HostId":"120358203-vanak-tehran"}')
    debug 2026-06-15T09:53:23.638+0000 7f85eeba0640  0 [dashboard INFO request] [::ffff:172.20.26.54:60281] [POST] [500] [0.019s] [admin] [215.0B] /api/rgw/bucket
    debug 2026-06-15T09:53:25.291+0000 7f862ae57640  0 log_channel(cluster) log [DBG] : pgmap v833: 449 pgs: 449 active+clean; 3.2 GiB data, 19 GiB used, 1.2 TiB / 1.2 TiB avail; 18 KiB/s rd, 1.8 KiB/s wr, 30 op/s
    ::ffff:172.29.244.12 - - [15/Jun/2026:09:53:26] "GET /metrics HTTP/1.1" 200 264108 "" "Prometheus/2.51.0" 
    

atached rgw log


Files

rgw-log.txt (15.1 KB) rgw-log.txt farhad khedriyan, 06/20/2026 09:51 AM

Related issues 2 (0 open — 2 closed)

Copied to Dashboard - Backport #78211: tentacle: Dashboard/RGW: Stale RGW user/account metadata cache in mgr after delete and recreateResolvednaman munet

Actions
Copied to Dashboard - Backport #78212: umbrella: Dashboard/RGW: Stale RGW user/account metadata cache in mgr after delete and recreateResolvednaman munet

Actions

FK Updated by farhad khedriyan 5 months ago Actions #1

  • Tracker changed from Bug to Tasks
  • Source deleted (other)
  • Regression deleted (Yes)
  • Severity deleted (3 - minor)

FK Updated by farhad khedriyan 5 months ago Actions #2

  • Tracker changed from Tasks to Bug
  • Regression set to No
  • Severity set to 3 - minor

NM Updated by naman munet 5 months ago Actions #3

  • Assignee changed from Afreen Misbah to naman munet

NM Updated by naman munet 5 months ago Actions #4

  • Pull request ID set to 69968

NM Updated by naman munet 5 months ago Actions #5

  • Status changed from New to Fix Under Review

UB Updated by Upkeep Bot 5 months ago Actions #6

  • Status changed from Fix Under Review to Resolved
  • Merge Commit set to ef47d68738188236df58d5a1100264bcad1464f9
  • Fixed In set to v21.3.0-1005-gef47d68738
  • Upkeep Timestamp set to 2026-07-14T08:17:50+00:00

AM Updated by Afreen Misbah 5 months ago Actions #7

  • Status changed from Resolved to Pending Backport
  • Target version changed from v20.2.1 to v22.0.0
  • Backport set to tentacle,umbrella

UB Updated by Upkeep Bot 5 months ago Actions #8

  • Copied to Backport #78211: tentacle: Dashboard/RGW: Stale RGW user/account metadata cache in mgr after delete and recreate added

UB Updated by Upkeep Bot 5 months ago Actions #9

  • Copied to Backport #78212: umbrella: Dashboard/RGW: Stale RGW user/account metadata cache in mgr after delete and recreate added

UB Updated by Upkeep Bot 5 months ago Actions #10

  • Tags (freeform) set to backport_processed

UB Updated by Upkeep Bot 3 months ago Actions #11

  • Status changed from Pending Backport to Resolved
  • Tags (freeform) deleted (backport_processed)
  • Upkeep Timestamp changed from 2026-07-14T08:17:50+00:00 to 2026-08-27T18:40:46+00:00
Actions

Also available in: PDF Atom