]> git.sur5r.net Git - bacula/bacula/blobdiff - regress/scripts/check_for_zombie_jobs
Backport from BEE
[bacula/bacula] / regress / scripts / check_for_zombie_jobs
index 6aec189173c0564e0b7777aae421e624e2c8b78e..2b1802a2e8c8efcf5616b4ca6fc91ffa5a7dd5d7 100755 (executable)
 if [ $# = 2 ] ; then
     client="$2"
 else 
-    client=${HOST}-fd
+    client="client"
 fi
 
 ${bin}/bconsole -c ${scripts}/bconsole.conf <<END_OF_DATA 2>&1 >/dev/null
 @output ${tmp}/dir.out
 status dir
 @output ${tmp}/fd.out
-status client=${client}
+status ${client}
 @output ${tmp}/sd.out
 status $1
 @output
@@ -31,6 +31,7 @@ if [ $? != 0 ] ; then
   echo " "
   echo "  !!!! Zombie Jobs in Director !!!!"
   echo "  !!!! Zombie Jobs in Director !!!!" >>test.out
+  cat ${tmp}/dir.out
   echo " "
   zstat=1
   exit 1
@@ -40,6 +41,7 @@ if [ $? != 0 ] ; then
   echo " "
   echo "  !!!! Zombie Jobs in File daemon !!!!"
   echo "  !!!! Zombie Jobs in File daemon !!!!" >>test.out
+  cat ${tmp}/fd.out
   echo " "
   zstat=1
   exit 1
@@ -49,6 +51,17 @@ if [ $? != 0 ] ; then
   echo " "
   echo "  !!!! Zombie Jobs in Storage daemon !!!!"
   echo "  !!!! Zombie Jobs in Storage daemon !!!!" >>test.out
+  cat ${tmp}/sd.out
+  echo " "
+  zstat=1
+  exit 1
+fi
+grep " READ " ${tmp}/sd.out 2>&1 >/dev/null
+if [ $? = 0 ]; then
+  echo " "
+  echo "  !!!! Zombie \"Read\" Jobs in Storage daemon !!!!"
+  echo "  !!!! Zombie \"Read\" Jobs in Storage daemon !!!!" >>test.out
+  cat ${tmp}/sd.out
   echo " "
   zstat=1
   exit 1