]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/dashboard: cleanup rbd-mirror process in dashboard e2e 53211/head
authorNizamudeen A <nia@redhat.com>
Tue, 29 Aug 2023 19:48:03 +0000 (01:18 +0530)
committerNizamudeen A <nia@redhat.com>
Wed, 30 Aug 2023 04:33:23 +0000 (10:03 +0530)
Fixes: https://tracker.ceph.com/issues/61703
Signed-off-by: Nizamudeen A <nia@redhat.com>
src/pybind/mgr/dashboard/run-frontend-e2e-tests.sh

index 2c28835887272c0f7e9a3e13c091c9a88ab080be..a481a983f40bb0f74a6f1c47ea40742eb377d92f 100755 (executable)
@@ -39,7 +39,7 @@ start_ceph() {
     # start rbd-mirror daemon in the cluster
     KEY=$(ceph auth get client.admin --format=json | jq -r .[0].key)
     MON_CLUSTER_1=$(grep "mon host" ${FULL_PATH_BUILD_DIR}/run/1/ceph.conf | awk '{print $4}')
-    ${FULL_PATH_BUILD_DIR}/bin/rbd-mirror --mon_host $MON_CLUSTER_1 --key $KEY -c ${FULL_PATH_BUILD_DIR}/run/1/ceph.conf &
+    ${FULL_PATH_BUILD_DIR}/bin/rbd-mirror --mon_host $MON_CLUSTER_1 --key $KEY -c ${FULL_PATH_BUILD_DIR}/run/1/ceph.conf
 
     set +x
 }
@@ -50,6 +50,11 @@ stop() {
         for cluster in ${CLUSTERS[@]}; do
             ../src/mstop.sh $cluster
         done
+        pids=$(pgrep rbd-mirror)
+        if [ -n "$pids" ]; then
+            echo Killing rbd-mirror processes: $pids
+            kill -9 $pids
+        fi
     fi
     exit $1
 }