Skip to content

os/bluestore: Skip unconfigured allocators in free-score - #69635

Merged
Jayaprakash-ibm merged 1 commit into
ceph:mainfrom
manya-dogra:wip-77462-handle_ceph_bluestore_tool_free_score_command_to_only_print_scores_of_devices_present
Aug 19, 2026
Merged

Jayaprakash-ibm merged 1 commit into
ceph:mainfrom
manya-dogra:wip-77462-handle_ceph_bluestore_tool_free_score_command_to_only_print_scores_of_devices_present

Conversation

@manya-dogra

@manya-dogra manya-dogra commented Jun 22, 2026 •

Copy link
Copy Markdown
Contributor

The free-score command queries all BlueFS allocators (block, bluefs-db, and bluefs-wal) even when some devices are not configured for an OSD, resulting in unnecessary query failures. Use inferring_bluefs_devices() to detect the BlueFS devices present under the OSD path and query only their corresponding allocators, so fragmentation scores are reported only for configured devices without unnecessary error messages.

Fixes: https://tracker.ceph.com/issues/77462

Test results:
Test Case 1: OSD deployed with only Data device

[root@manya-test-0 /]# ceph-bluestore-tool free-score --path /var/lib/ceph/8775816c-8745-11f1-80a5-525400863160/osd.0
block:
{
    "fragmentation_score": 2.4795592183013068e-05
}

Test Case 2: OSD deployed with Data + DB devices

[root@manya-test-0 /]# ceph-bluestore-tool free-score --path /var/lib/ceph/8775816c-8745-11f1-80a5-525400863160/osd.1
block:
{
    "fragmentation_score": 2.2194734544009199e-06
}

bluefs-db:
{
    "fragmentation_score": 9.3238755176527598e-05
}

Test Case 3: OSD deployed with Data + DB + WAL devices

[root@manya-test-0 /]# ceph-bluestore-tool free-score --path /var/lib/ceph/8775816c-8745-11f1-80a5-525400863160/osd.2
block:
{
    "fragmentation_score": 1.2330414354017335e-06
}

bluefs-db:
{
    "fragmentation_score": 9.3171943483155473e-05
}

bluefs-wal:
{
    "fragmentation_score": 0
}

Contribution Guidelines

  • To sign and title your commits, please refer to Submitting Patches to Ceph.

  • If you are submitting a fix for a stable branch (e.g. "quincy"), please refer to Submitting Patches to Ceph - Backports for the proper workflow.

  • When filling out the below checklist, you may click boxes directly in the GitHub web UI. When entering or editing the entire PR message in the GitHub web UI editor, you may also select a checklist item by adding an x between the brackets: [x]. Spaces and capitalization matter when checking off items this way.

Checklist

  • Tracker (select at least one)
    • References tracker ticket
    • Very recent bug; references commit where it was introduced
    • New feature (ticket optional)
    • Doc update (no ticket needed)
    • Code cleanup (no ticket needed)
  • Component impact
    • Affects Dashboard, opened tracker ticket
    • Affects Orchestrator, opened tracker ticket
    • No impact that needs to be tracked
  • Documentation (select at least one)
    • Updates relevant documentation
    • No doc update is appropriate
  • Tests (select at least one)
Show available Jenkins commands

You must only issue one Jenkins command per-comment. Jenkins does not understand
comments with more than one command.

@manya-dogra
manya-dogra requested a review from a team as a code owner June 22, 2026 10:51
@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

14 similar comments
@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@ceph-jenkins

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. Since you, the author, are not a member of the Ceph GitHub Org yet, our CI will not automatically run. Any member of the Ceph Org may comment "ok - to - test" (without the dashes) to allow the Jenkins jobs to run.

@aadhikale

Copy link
Copy Markdown
Contributor

ok to test

@Jayaprakash-ibm Jayaprakash-ibm changed the title src/os/bluestore: Skip unconfigured allocators in free-score os/bluestore: Skip unconfigured allocators in free-score Jun 23, 2026
Comment thread src/os/bluestore/bluestore_tool.cc Resolved
@manya-dogra
manya-dogra force-pushed the wip-77462-handle_ceph_bluestore_tool_free_score_command_to_only_print_scores_of_devices_present branch from 3678137 to 0f38cbb Compare June 24, 2026 09:57
@ifed01
ifed01 self-requested a review June 29, 2026 11:27
@manya-dogra
manya-dogra force-pushed the wip-77462-handle_ceph_bluestore_tool_free_score_command_to_only_print_scores_of_devices_present branch 2 times, most recently from de5d6b8 to cf68141 Compare July 21, 2026 14:02
Comment thread src/os/bluestore/bluestore_tool.cc Resolved
@manya-dogra
manya-dogra force-pushed the wip-77462-handle_ceph_bluestore_tool_free_score_command_to_only_print_scores_of_devices_present branch from cf68141 to 917f1ab Compare July 24, 2026 12:55
Comment thread src/os/bluestore/bluestore_tool.cc Resolved
@manya-dogra
manya-dogra force-pushed the wip-77462-handle_ceph_bluestore_tool_free_score_command_to_only_print_scores_of_devices_present branch from 917f1ab to ac94890 Compare July 27, 2026 12:30

@Jayaprakash-ibm Jayaprakash-ibm left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Jayaprakash-ibm

Copy link
Copy Markdown
Contributor

jenkins test submodules

@Jayaprakash-ibm

Copy link
Copy Markdown
Contributor

jenkins test signed

@Jayaprakash-ibm

Copy link
Copy Markdown
Contributor

jenkins test make check

@Jayaprakash-ibm

Copy link
Copy Markdown
Contributor

jenkins test make check arm64

Comment thread src/os/bluestore/bluestore_tool.cc Resolved
 The free-score command queries all BlueFS allocators (block, bluefs-db,
 and bluefs-wal) even when some devices are not configured for an OSD,
 resulting in unnecessary query failures. Use inferring_bluefs_devices()
 to detect the BlueFS devices present under the OSD path and query only
 their corresponding allocators, so fragmentation scores are reported
 only for configured devices without unnecessary error messages.

Fixes: https://tracker.ceph.com/issues/77462

Signed-off-by: Manya Dogra <[email protected]>
@manya-dogra
manya-dogra force-pushed the wip-77462-handle_ceph_bluestore_tool_free_score_command_to_only_print_scores_of_devices_present branch from ac94890 to ccac808 Compare August 6, 2026 12:52
@ifed01

ifed01 commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

jenkins retest this please

@Jayaprakash-ibm

Copy link
Copy Markdown
Contributor

This PR has been added to wip-jaya-bs-testing-12-08-2026

@Jayaprakash-ibm

Copy link
Copy Markdown
Contributor

@Jayaprakash-ibm
Jayaprakash-ibm merged commit eb2eb57 into ceph:main Aug 19, 2026
7 checks passed
@github-actions

Copy link
Copy Markdown

This is an automated message by src/script/redmine-upkeep.py.

I have resolved the following tracker ticket due to the merge of this PR:

No backports are pending for the ticket. If this is incorrect, please update the tracker
ticket and reset to Pending Backport state.

Update Log: https://github.com/ceph/ceph/actions/runs/32238465249

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants