From 0e5470001534d20ebe3b14e5717001c354f46f53 Mon Sep 17 00:00:00 2001 From: Kern Sibbald Date: Mon, 12 Dec 2005 15:08:09 +0000 Subject: [PATCH] Update git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@2664 91ce42f0-d328-0410-95d8-f526ca767f89 --- regress/scripts/do_sed | 8 ++------ regress/tests/bscan-tape | 2 +- regress/tests/bscan-test | 26 +++++++++++++++++++++----- 3 files changed, 24 insertions(+), 12 deletions(-) diff --git a/regress/scripts/do_sed b/regress/scripts/do_sed index 477d2fc269..61614122f2 100755 --- a/regress/scripts/do_sed +++ b/regress/scripts/do_sed @@ -11,11 +11,7 @@ if test $# != 6 ; then fi out="/tmp/sed_tmp" cwd=`pwd` -host=`hostname | tr '.' ' ' | cut -f 1 -d ' '` -if test x$host = x ; then - host=localhost -fi -host="localhost" +HOST="localhost" # Create sed command script echo "s%@sbindir@%${cwd}/bin%g" >${out} echo "s%@scriptdir@%${cwd}/bin%g" >>${out} @@ -26,7 +22,7 @@ echo "s%@job_email@%${1}%g" >>${out} echo "s%@tape_drive@%${2}%g" >>${out} echo "s%@autochanger@%${3}%g" >>${out} echo "s%@tmpdir@%${cwd}/tmp%g" >>${out} -echo "s%@hostname@%${host}%g" >>${out} +echo "s%@hostname@%${HOST}%g" >>${out} echo "s%@changer_path@%${4}%g" >>${out} echo "s%@tape_drive1@%${5}%g" >>${out} echo "s%@smtp_host@%${6}%g" >>${out} diff --git a/regress/tests/bscan-tape b/regress/tests/bscan-tape index 6fe38d0bb2..5225103a89 100755 --- a/regress/tests/bscan-tape +++ b/regress/tests/bscan-tape @@ -27,7 +27,7 @@ echo " === Starting bscan-tape at `date +%R:%S` ===" >>working/log echo " " cat <tmp/bconcmds -@$out /dev/null +@output /dev/null estimate job=NightlySave listing estimate job=NightlySave listing estimate job=NightlySave listing diff --git a/regress/tests/bscan-test b/regress/tests/bscan-test index cff1a52022..3e854da219 100755 --- a/regress/tests/bscan-test +++ b/regress/tests/bscan-test @@ -51,6 +51,7 @@ messages quit END_OF_DATA +# run backup if test "$debug" -eq 1 ; then bin/bacula start cat tmp/bconcmds | bin/bconsole -c bin/bconsole.conf @@ -62,17 +63,21 @@ fi scripts/check_for_zombie_jobs storage=File1 bin/bacula stop 2>&1 >/dev/null echo "volume=TestVolume001|TestVolume002" >tmp/bscan.bsr -bin/bscan -w working -m -s -v -b tmp/bscan.bsr -c bin/bacula-sd.conf ${cwd}/tmp 2>&1 >/dev/null -#bin/bscan -w working -m -s -v -b tmp/bscan.bsr -c bin/bacula-sd.conf ${cwd}/tmp -bin/bacula start 2>&1 >/dev/null -bin/bconsole -c bin/bconsole.conf <&1 >/dev/null -#bin/bconsole -c bin/bconsole.conf <&1 >/dev/null +fi + +cat <tmp/bconcmds @$out /dev/null messages @$out tmp/log2.out @# @# now do a restore @# +@#setdebug level=400 storage=File1 restore bootstrap=${cwd}/tmp/kern.bsr where=${cwd}/tmp/bacula-restores select all storage=File1 done yes wait @@ -80,6 +85,17 @@ messages @$out quit END_OF_DATA + +# now run restore +if test "$debug" -eq 1 ; then + bin/bacula start + cat tmp/bconcmds | bin/bconsole -c bin/bconsole.conf +else + bin/bacula start 2>&1 >/dev/null + cat tmp/bconcmds | bin/bconsole -c bin/bconsole.conf 2>&1 >/dev/null +fi + + scripts/check_for_zombie_jobs storage=File1 bin/bacula stop 2>&1 >/dev/null grep "^ Termination: *Backup OK" tmp/log1.out 2>&1 >/dev/null -- 2.39.5