From: Kern Sibbald Date: Fri, 4 Jan 2008 16:29:55 +0000 (+0000) Subject: Update X-Git-Tag: Release-7.0.0~5187 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=44ef371364acc96d17ac334e7bde258371320a37;p=bacula%2Fbacula Update git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@6215 91ce42f0-d328-0410-95d8-f526ca767f89 --- diff --git a/regress/tests/relabel-1t1d-tape b/regress/tests/relabel-1t1d-tape new file mode 100755 index 0000000000..69a36f61ab --- /dev/null +++ b/regress/tests/relabel-1t1d-tape @@ -0,0 +1,94 @@ +#!/bin/sh +# +# Run a simple backup of the Bacula build directory using the compressed option +# then backup four times, each with incremental then finally restore. +# It should require at least 4 different bsrs. +# +TestName="relabel-1t1d-tape" +JobName=Relabeltape +. scripts/functions + +scripts/cleanup-tape +scripts/copy-tape-confs +echo "${cwd}/build" >${cwd}/tmp/file-list + +change_jobname $JobName +start_test + +cat <${cwd}/tmp/bconcmds +@output /dev/null +messages +@$out ${cwd}/tmp/log1.out +label storage=DDS-4 volume=TestVolume001 slot=0 pool=Default +run job=$JobName level=Full yes +wait +messages +add pool=Default storage=DDS-4 +0 +TestVolume002 +@# set status to append +update volume=TestVolume001 +1 +. +run job=$JobName level=Full yes +wait +unmount storage=DDS-4 +unmount storage=DDS-4 +@#setdebug level=150 storage=DDS-4 +purge volume=TestVolume001 +relabel oldvolume=TestVolume001 volume=TestVolume003 slot=0 pool=Default storage=DDS-4 +list volumes +mount storage=DDS-4 +messages +wait +run job=$JobName level=Full yes +wait +messages +@$out +quit +END_OF_DATA + +run_bacula +check_for_zombie_jobs storage=DDS-4 + + +echo "Backup done" +# +# now do several restores to ensure we cleanup between jobs +# +cat <${cwd}/tmp/bconcmds +@$out /dev/null +restore where=${cwd}/tmp/bacula-restores select all done +yes +wait +restore where=${cwd}/tmp/bacula-restores select all done +yes +wait +@$out ${cwd}/tmp/log2.out +@# +@# now unmount the tape and start two restores +@# at the same time +@# +unmount storage=DDS-4 +restore where=${cwd}/tmp/bacula-restores select all done +yes +restore where=${cwd}/tmp/bacula-restores select +unmark * +mark * +done +yes +mount storage=DDS-4 +wait +messages +@$out +quit +END_OF_DATA + +run_bconsole + +check_for_zombie_jobs storage=DDS-4 +stop_bacula + +check_two_logs +check_restore_diff +end_test diff --git a/regress/tests/relabel-tape b/regress/tests/relabel-tape deleted file mode 100755 index 69a36f61ab..0000000000 --- a/regress/tests/relabel-tape +++ /dev/null @@ -1,94 +0,0 @@ -#!/bin/sh -# -# Run a simple backup of the Bacula build directory using the compressed option -# then backup four times, each with incremental then finally restore. -# It should require at least 4 different bsrs. -# -TestName="relabel-1t1d-tape" -JobName=Relabeltape -. scripts/functions - -scripts/cleanup-tape -scripts/copy-tape-confs -echo "${cwd}/build" >${cwd}/tmp/file-list - -change_jobname $JobName -start_test - -cat <${cwd}/tmp/bconcmds -@output /dev/null -messages -@$out ${cwd}/tmp/log1.out -label storage=DDS-4 volume=TestVolume001 slot=0 pool=Default -run job=$JobName level=Full yes -wait -messages -add pool=Default storage=DDS-4 -0 -TestVolume002 -@# set status to append -update volume=TestVolume001 -1 -. -run job=$JobName level=Full yes -wait -unmount storage=DDS-4 -unmount storage=DDS-4 -@#setdebug level=150 storage=DDS-4 -purge volume=TestVolume001 -relabel oldvolume=TestVolume001 volume=TestVolume003 slot=0 pool=Default storage=DDS-4 -list volumes -mount storage=DDS-4 -messages -wait -run job=$JobName level=Full yes -wait -messages -@$out -quit -END_OF_DATA - -run_bacula -check_for_zombie_jobs storage=DDS-4 - - -echo "Backup done" -# -# now do several restores to ensure we cleanup between jobs -# -cat <${cwd}/tmp/bconcmds -@$out /dev/null -restore where=${cwd}/tmp/bacula-restores select all done -yes -wait -restore where=${cwd}/tmp/bacula-restores select all done -yes -wait -@$out ${cwd}/tmp/log2.out -@# -@# now unmount the tape and start two restores -@# at the same time -@# -unmount storage=DDS-4 -restore where=${cwd}/tmp/bacula-restores select all done -yes -restore where=${cwd}/tmp/bacula-restores select -unmark * -mark * -done -yes -mount storage=DDS-4 -wait -messages -@$out -quit -END_OF_DATA - -run_bconsole - -check_for_zombie_jobs storage=DDS-4 -stop_bacula - -check_two_logs -check_restore_diff -end_test