From 104932b18216851c59ea4c6a59057104f07948a0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gardais=20J=C3=A9r=C3=A9my?= Date: Wed, 3 Jun 2020 17:51:31 +0200 Subject: [PATCH] Exit with error if the script end with queue enable --- cluster/disable.host.queue.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/cluster/disable.host.queue.sh b/cluster/disable.host.queue.sh index 3d85d74..cc9b11a 100755 --- a/cluster/disable.host.queue.sh +++ b/cluster/disable.host.queue.sh @@ -155,6 +155,12 @@ for host: ${RED}${sge_hostname:=/dev/null}${COLOR_DEBUG}." is_queue_enable "${sge_hostname}" "${sge_queue_name}" \ && disable_sge_queue "${sge_hostname}" "${sge_queue_name}" + ## If the queue is still enable + ### Exit with error + is_queue_enable "${sge_hostname}" "${sge_queue_name}" \ + && printf '%b\n' "${RED}ERROR ${sge_queue_name}@${sge_hostname} is still enable.${RESET}" \ + && exit 4 + } # }}}