Previously, we relied on the __GNUC__ macro to check for std::atomic<std::shared_ptr>
support, which was inaccurate. This approach failed with Clang builds using libstdc++,
even when the feature was implemented. The warning looks like:
```
/usr/lib/gcc/x86_64-redhat-linux/15/../../../../include/c++/15/bits/shared_ptr_atomic.h:131:5: note: 'atomic_load_explicit<std::vector<entity_addrvec_t>>' has been explicitly marked deprecated here
131 | _GLIBCXX20_DEPRECATED_SUGGEST("std::atomic<std::shared_ptr<T>>")
| ^
```
This change uses a standard-compliant feature test macro (__cpp_lib_atomic_shared_ptr)
to correctly detect support for std::atomic<std::shared_ptr>. This resolves compilation
issues and improves portability across different compilers and standard library
implementations.
Ilya Dryomov [Thu, 20 Mar 2025 17:28:44 +0000 (18:28 +0100)]
rbd: mirror_uuids -> mirror_uuid in remote mirror peer listing
... in "rbd mirror image status" and "rbd mirror pool status --verbose"
formatted outputs. In unformatted outputs this value is shown in place
of a name in case a site name isn't available.
Ilya Dryomov [Thu, 20 Mar 2025 16:10:47 +0000 (17:10 +0100)]
rbd: extend use of "none" placeholder to IMAGES section
Currently if there are no mirror-enabled images, IMAGES section
in "rbd mirror pool status --verbose" output isn't terminated:
$ rbd mirror pool status data --verbose
health: OK
daemon health: OK
image health: OK
images: 0 total
DAEMONS
service 4388:
...
health: OK
IMAGES$
DAEMONS section has a "none" placeholder for when there are no
rbd-mirror daemons running. Fix some issues with the separator logic
and employ the placeholder in IMAGES section:
$ rbd mirror pool status data --verbose
health: OK
daemon health: OK
image health: OK
images: 0 total
DAEMONS
service 4388:
...
health: OK
IMAGES
none
$
$ rbd mirror pool status data --verbose
health: UNKNOWN
daemon health: UNKNOWN
image health: OK
images: 0 total
rgw: fix the version in DOCODE_START() of RGWZoneGroupPlacementTier
This commit fixes an undetected merge conflict between PRs #61745
and #60159. The dencoding problem has been introduced very recently,
it is straightforward and causes failures of the make check bot
everywhere, therefore -- if no objections -- I want to merge this
patch without the Teuthology testing.
Kefu Chai [Mon, 24 Mar 2025 02:05:25 +0000 (10:05 +0800)]
librbd: migrate from boost::variant to std::variant
migrate from boost::variant to std::variant
Complete migration started in commit 017f3339c, replacing boost::variant with
std::variant throughout the librbd codebase. This change is part of our ongoing
effort to reduce third-party dependencies by leveraging C++ standard library
alternatives where possible.
Benefits include:
- Improved code readability and maintainability
- Reduced external dependency surface
- More consistent API usage with other components
Aashish Sharma [Tue, 25 Mar 2025 11:35:05 +0000 (17:05 +0530)]
mgr/dashboard: fix image filter's query on rbd-details grafana panel
The image filter on the RBD Details grafana panel is using a query with a type "label_values(ceph_rbd_read_ops{cluster=~\"$cluster\", , pool=\"$pool\"}, image)". The extra comma needs to be removed.
Ilya Dryomov [Tue, 25 Mar 2025 08:13:27 +0000 (09:13 +0100)]
mgr/rbd_support: always parse interval and start_time in Schedules::remove()
Commit 1b62447071a9 ("mgr/rbd_support: fix schedule remove") addressed
the issue that it was concerned with in a rather suboptimal way: instead
of moving the parsing of interval and start_time upfront to be able to
bail early, it wrapped from_string() constructors with try/finally and
left the conditional behavior in place.
Kefu Chai [Tue, 25 Mar 2025 04:17:35 +0000 (12:17 +0800)]
common: remove spaces before literal operator
clang 20 complains when compiling a user-defined literal operator
with spaces before the underscore. so let's drop the space to be
compliant to
[CWG2521](https://cplusplus.github.io/CWG/issues/2521.html).
```
/home/kefu/dev/ceph/src/common/options.h:415:41: warning: identifier '_min' preceded by whitespace in a literal operator declaration is deprecated [-Wdeprecated-literal-operator]
415 | constexpr unsigned long long operator"" _min (unsigned long long min) {
| ~~~~~~~~~~~^~~~
| operator""_min
```
Patrick Donnelly [Mon, 24 Mar 2025 15:50:50 +0000 (11:50 -0400)]
mgr: add status command
The Rook operator relies on a `status` (asok) command to the mgr to verify it
is operational. However, this command was actually served by the CephFS
`Client` library that the ceph-mgr daemon statically linked in and used for
sending MDS commands. That statically linked client was removed via 048fc68c
(case insensitive directory tree feature).
So, add a legitimate ceph-mgr status command which simply outputs an empty
dictionary and returns success (0). TBD on adding useful information.
Fixes: 048fc68c517f50b9978457f478ca4638f01caa09 Fixes: https://tracker.ceph.com/issues/70571 Signed-off-by: Patrick Donnelly <pdonnell@ibm.com>
Ilya Dryomov [Fri, 21 Mar 2025 13:43:50 +0000 (14:43 +0100)]
librbd: respect rbd_default_snapshot_quiesce_mode in group_snap_create()
Make group_snap_create() behave the same as snap_create() and
mirror_image_create_snapshot(): APIs that don't take RBD_SNAP_CREATE_
flags explicitly should respect rbd_default_snapshot_quiesce_mode
option.
Zac Dover [Mon, 24 Mar 2025 12:26:11 +0000 (22:26 +1000)]
src/common: add guidance for deep-scrubbing ratio warning
Add an explanation of how to set the value of
"mon_warn_pg_not_deep_scrubbed_ratio" to the confval definition of that
variable. Although this variable contains the string "mon", it is set on
the Manager. I have added a note to direct users to set this value on
the Manager.
This issue was pointed out by Petr Tlapa on Slack in late March of 2025.
Aashish Sharma [Wed, 19 Mar 2025 11:29:27 +0000 (16:59 +0530)]
mgr/dashboard: fix blockUI implementation
Enable/Disable mgr modules from SMB page, Rgw multisite Page and Mgr Modules page doesn't give proper message and doesn't block the UI
This PR intends to fix this issue
Fixes: https://tracker.ceph.com/issues/70588 Signed-off-by: Naman Munet <naman.munet@ibm.com>
Before: As the tenant was not passed in lifecycle calls made through bucket details > tiering tab, & also account_id was not resolved to the user of the bucket, hence not able to manage the Tiering configuration lifecycle changes
After: Account_id is resolved to user_id and tenant is additionally passed to the lifecycle API so as to handle the tenanted bucket scenario
Nizamudeen A [Thu, 20 Mar 2025 08:51:50 +0000 (14:21 +0530)]
mgr/dashboard: use existing pools for cephfs vol creation
We can use the newly introduced data and metadata params to create a vol
with those pools.
UI is being intelligent by filtering out the used pools and only uses
the pools that are labeled by cephfs and also not in use. To figure out
a pool is in use or not, we are fetching the pool stats and checking its
used_bytes.
Note: Using ec pools for data pool layout is something discouraged
according to offical doc: https://docs.ceph.com/en/latest/cephfs/createfs/#creating-a-file-system
We can force it but for now I have disabled it entirely in the dashboard
unless people say its okay to do it.
One more extra thing I am doing here is to add a note on deleting a
filesystem that the underlying pools and mds daemons will be removed.
Fixes: https://tracker.ceph.com/issues/70600 Signed-off-by: Nizamudeen A <nia@redhat.com>