From: Vallari Agrawal Date: Wed, 9 Apr 2025 08:21:39 +0000 (+0530) Subject: mgr/cephadm/module.py: Run ok_to_stop logic for stop X-Git-Tag: v21.0.0~256^2~743^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=16bc30c9553e1ec8b4cb26c60bac86e1cf28bf43;p=ceph.git mgr/cephadm/module.py: Run ok_to_stop logic for stop Also run ok_to_stop logic for daemons when stopping a daemon with "ceph orch daemon stop " Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=2279225 Signed-off-by: Vallari Agrawal --- diff --git a/src/pybind/mgr/cephadm/module.py b/src/pybind/mgr/cephadm/module.py index 1a5389d0260..7c305096569 100644 --- a/src/pybind/mgr/cephadm/module.py +++ b/src/pybind/mgr/cephadm/module.py @@ -2667,7 +2667,7 @@ Then run the following: raise OrchestratorError( f'Unable to schedule redeploy for {daemon_name}: No standby MGRs') - if action == 'restart' and not force: + if action in ['restart', 'stop'] and not force: r = service_registry.get_service(daemon_type_to_service( d.daemon_type)).ok_to_stop([d.daemon_id], force=False) if r.retval: