Bug #79516
closedradosgw-admin gc list and process accepts invalid --bypass-gc argument
0%
Description
If we run radosgw-admin gc list --bypass-gc or radosgw-admin gc process --bypass-gc, the command results in a below crash.
{{*** Caught signal (Segmentation fault) ** }}
{{ in thread 7f763af1cc40 thread_name:radosgw-admin }}
{{ ceph version 20.2.1-294.el10cp (71400d000eb272c5f3f442a9d237e4981f013537) tentacle (stable - RelWithDebInfo) }}
{{ 1: /lib64/libc.so.6(+0x411c0) [0x7f763d6681c0] }}
{{ 2: (RGWGC::process(bool, optional_yield)+0x39) [0x5646da149729] }}
{{ 3: main() }}
{{ 4: /lib64/libc.so.6(+0x2a58e) [0x7f763d65158e] }}
{{ 5: __libc_start_main() }}
{{ 6: _start() }}
Segmentation fault (core dumped)
{{ }}
Expected:
--bypass-gc is documented for use with bucket deletion to skip GC and delete objects. Using it with gc process does not make sense because GC processing requires GC initialization.
Currently, the GC_PROCESS and GC_LIST handler does not check whether gc is initialized before invoking gc->process() and gc->list().
Proposed Fix: Add a pre-check to return a proper error message when --bypass-gc is used with gc list or gc process, preventing the crash.
JI Updated by J. Eric Ivancich 4 months ago
- Status changed from New to Fix Under Review
JI Updated by J. Eric Ivancich 3 months ago
- Pull request ID set to 71071
JI Updated by J. Eric Ivancich 3 months ago
- Status changed from Fix Under Review to Pending Backport
- Backport set to squid, tentacle, umbrella
UB Updated by Upkeep Bot 3 months ago
- Copied to Backport #80254: squid: radosgw-admin gc list and process accepts invalid --bypass-gc argument added
UB Updated by Upkeep Bot 3 months ago
- Copied to Backport #80255: tentacle: radosgw-admin gc list and process accepts invalid --bypass-gc argument added
UB Updated by Upkeep Bot 3 months ago
- Copied to Backport #80256: umbrella: radosgw-admin gc list and process accepts invalid --bypass-gc argument added
UB Updated by Upkeep Bot 3 months ago
- Status changed from Pending Backport to Backporting
- Merge Commit set to b844433288135cf2abdc30d7e1f141c016108d22
- Fixed In set to v21.3.0-2893-gb844433288
- Upkeep Timestamp set to 2026-09-03T14:30:43+00:00