Skip to content

mgr/volumes: allow disabling async job threads#54396

Merged
vshankar merged 7 commits intoceph:mainfrom
rishabh-d-dave:mgr-vol-no-del
Mar 13, 2025
Merged

mgr/volumes: allow disabling async job threads#54396
vshankar merged 7 commits intoceph:mainfrom
rishabh-d-dave:mgr-vol-no-del

Conversation

@rishabh-d-dave
Copy link
Contributor

@rishabh-d-dave rishabh-d-dave commented Nov 7, 2023

Add a new mgr config options that allows pausing async purge threads and async cloner threads.

Fixes: https://tracker.ceph.com/issues/61903
Fixes: https://tracker.ceph.com/issues/68630

TODO

Contribution Guidelines

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
  • jenkins retest this please
  • jenkins test classic perf
  • jenkins test crimson perf
  • jenkins test signed
  • jenkins test make check
  • jenkins test make check arm64
  • jenkins test submodules
  • jenkins test dashboard
  • jenkins test dashboard cephadm
  • jenkins test api
  • jenkins test docs
  • jenkins render docs
  • jenkins test ceph-volume all
  • jenkins test ceph-volume tox
  • jenkins test windows

@github-actions
Copy link

This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved

Copy link
Contributor

@vshankar vshankar left a comment

Choose a reason for hiding this comment

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

@rishabh-d-dave What about comment 6b9f3cf#r1386395240 ?

@vshankar
Copy link
Contributor

@rishabh-d-dave Is this ready for review?

@github-actions
Copy link

This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved


self.run_ceph_cmd(f'fs subvolume rm {v} {sv}')
self._assert_trashed_sv_is_unpurged(sv, sv_path, sv_files)
time.sleep(7)
Copy link
Contributor

Choose a reason for hiding this comment

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

ping?? (unresolved comment)

@rishabh-d-dave
Copy link
Contributor Author

@vshankar PTAL

@vshankar
Copy link
Contributor

@vshankar PTAL

On this now...

Copy link
Contributor

@vshankar vshankar left a comment

Choose a reason for hiding this comment

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

LGTM

@vshankar
Copy link
Contributor

This PR is under test in https://tracker.ceph.com/issues/69939.

@github-actions
Copy link

This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved

Copy link
Contributor

@vshankar vshankar left a comment

Choose a reason for hiding this comment

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

I'm seeing a couple of test failures related to volume plugin. This change is the only mgr/volumes related changes in the test branch.

@rishabh-d-dave - could you please check the failures to assess if those are related to this change? If not, I will create trackers for the same and proceed with merging.

@rishabh-d-dave
Copy link
Contributor Author

@vshankar Issue has been fixed. All tests in fs:volumes are passing now - https://pulpito.ceph.com/rishabh-2025-03-10_02:36:23-fs:volumes-rishabh-mgr-vol-no-del-testing-default-smithi/

@rishabh-d-dave
Copy link
Contributor Author

about last push: removed DNM commit

@vshankar
Copy link
Contributor

@vshankar Issue has been fixed. All tests in fs:volumes are passing now - https://pulpito.ceph.com/rishabh-2025-03-10_02:36:23-fs:volumes-rishabh-mgr-vol-no-del-testing-default-smithi/

Could you explain what the issue was and the commit (new or existing) where the fix has been made?

@rishabh-d-dave
Copy link
Contributor Author

rishabh-d-dave commented Mar 10, 2025

@vshankar

@vshankar Issue has been fixed. All tests in fs:volumes are passing now - https://pulpito.ceph.com/rishabh-2025-03-10_02:36:23-fs:volumes-rishabh-mgr-vol-no-del-testing-default-smithi/

Could you explain what the issue was and the commit (new or existing) where the fix has been made?

The fix is in the last diff, specifically here - https://github.com/ceph/ceph/compare/db7d9131f4e2d70ec627d5166f76891714d60306..69c8ec7d06011e4632c55872d7d356fdf34038d5#diff-7ac80b107445f14d5cfc30196533c08eaafd56c101cae84a0f55df526a229eceR309. It was due to a leftover code when the name of the variable was changed.

EDIT:

fs:volumes runs successfully for the current version of this PR -
https://pulpito.ceph.com/rishabh-2025-03-10_02:36:23-fs:volumes-rishabh-mgr-vol-no-del-testing-default-smithi/
https://pulpito.ceph.com/rishabh-2025-03-10_02:04:23-fs:volumes-rishabh-mgr-vol-no-del-testing-default-smithi/
https://pulpito.ceph.com/rishabh-2025-03-10_03:06:58-fs:volumes-rishabh-mgr-vol-no-del-testing-default-smithi/

@rishabh-d-dave
Copy link
Contributor Author

jenkins test make check

@vshankar
Copy link
Contributor

This PR is under test in https://tracker.ceph.com/issues/70394.

@github-actions
Copy link

This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved

@vshankar
Copy link
Contributor

@rishabh-d-dave please rebase.

Add mechansim that allows pausing/resuming of the entire async job
machinery that queues, launches and picks next async job; both async
jobs, clones as well as purges.

And then add mgr/vol config option pause_purging and pause_cloning so
that both of these async jobs can be paused and resumed individually.

Fixes: https://tracker.ceph.com/issues/61903
Fixes: https://tracker.ceph.com/issues/68630
Signed-off-by: Rishabh Dave <ridave@redhat.com>
Whitespace is not removed from the end of the stdout returned by the
method get_ceph_cmd_stdout(). Follow the same policy here since it is
better to not do so (this whitespace can be useful, when copying Ceph
auth keyrings from stdout to a file) and also for sake of uniformity of
interfaces.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
Setting MGR config option mgr/volumes/pause_purging to true halts
all ongoing purges and allows no new purging to begin until this option
is changed to false. Add tests for this.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
Trash directory for a volume is not created by default. If
_wait_for_trash_empty() in test_volumes.py encounters absence of trash
directory, return true.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
mgr/vol config option pause_cloning allows pausing of cloner threads.
Add tests for this.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
Update documentation for add information about mgr/vol config options
"pause_purging" and "pause_cloning".

Signed-off-by: Rishabh Dave <ridave@redhat.com>
Added release notes for mgr/vol config option "pause_purging and
"pause_cloning".

Signed-off-by: Rishabh Dave <ridave@redhat.com>
@rishabh-d-dave
Copy link
Contributor Author

jenkins test make check

@rishabh-d-dave
Copy link
Contributor Author

jenkins test api

@vshankar
Copy link
Contributor

fs:volumes run: https://pulpito.ceph.com/vshankar-2025-03-13_10:45:26-fs:volumes-wip-vshankar-testing-20250313.072951-debug-testing-default-smithi/

I'm running the entire fs suite too, but for this change fs:volumes test would suffice and can be merged once that passes. I will link the run wiki entry later.

@rishabh-d-dave
Copy link
Contributor Author

fs:volumes run: https://pulpito.ceph.com/vshankar-2025-03-13_10:45:26-fs:volumes-wip-vshankar-testing-20250313.072951-debug-testing-default-smithi/

I'm running the entire fs suite too, but for this change fs:volumes test would suffice and can be merged once that passes. I will link the run wiki entry later.

@vshankar he tests linked above have passed.

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