From b5e6a0c24e59785cd4e8efacfd6ca8852efe0a8d Mon Sep 17 00:00:00 2001 From: Vallari Agrawal Date: Tue, 14 Jan 2025 09:22:31 +0530 Subject: [PATCH] qa/tasks/nvmeof.py: Do not use 'systemctl start' in thrasher Instead use 'daemon start' in revive_daemon() to bring up gateways thrashed with 'systemctl stop'. This is because 'systemctl start' method seems to temporary issues. Signed-off-by: Vallari Agrawal --- qa/tasks/nvmeof.py | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/qa/tasks/nvmeof.py b/qa/tasks/nvmeof.py index 1009f3860f74e..e5c60f195bd2a 100644 --- a/qa/tasks/nvmeof.py +++ b/qa/tasks/nvmeof.py @@ -398,7 +398,8 @@ class NvmeofThrasher(Thrasher, Greenlet): d_name ], check_status=False) elif chosen_method == "systemctl_stop": - daemon.stop() + # To bypass is_started logic of CephadmUnit + daemon.remote.sh(daemon.stop_cmd, check_status=False) elif chosen_method == "daemon_remove": daemon.remote.run(args=[ "ceph", "orch", "daemon", "rm", @@ -407,16 +408,20 @@ class NvmeofThrasher(Thrasher, Greenlet): return chosen_method def revive_daemon(self, daemon, killed_method): + name = '%s.%s' % (daemon.type_, daemon.id_) if killed_method == "ceph_daemon_stop": - name = '%s.%s' % (daemon.type_, daemon.id_) daemon.remote.run(args=[ "ceph", "orch", "daemon", "restart", name ]) + # note: temporarily use 'daemon start' to restart + # daemons instead of 'systemctl start' elif killed_method == "systemctl_stop": - daemon.restart() + daemon.remote.run(args=[ + "ceph", "orch", "daemon", "start", + name + ]) else: - name = '%s.%s' % (daemon.type_, daemon.id_) daemon.remote.run(args=[ "ceph", "orch", "daemon", "start", name -- 2.39.5