]> git.sur5r.net Git - bacula/bacula/blobdiff - regress/tests/multi2-storage-test
Make out of freespace non-fatal for removable devices -- i.e. behaves like tape
[bacula/bacula] / regress / tests / multi2-storage-test
index d8e2889fa3d952b46c34a0fe1871d4add9156164..8178e22377e9084d8bd1704e68a9288483d29fe8 100755 (executable)
@@ -1,11 +1,18 @@
 #!/bin/sh
+#
+# Copyright (C) 2000-2015 Kern Sibbald
+# License: BSD 2-Clause; see file LICENSE-FOSS
+#
+
 #
 # This script uses the virtual disk autochanger
 #
 TestName="multi-storage-test"
-JobName=backup
+JobName=NightlySave
 . scripts/functions
 
+export REGRESS_CHECK_CORRUPTION=no
+
 scripts/cleanup
 scripts/copy-2disk-confs
 scripts/prepare-disk-changer
@@ -21,7 +28,7 @@ for i in 2 3 4; do
   if (/(Archive|Changer) Device/) { $_ =~ s:$tmp:$tmp/$i:}
   print;
   ' $conf/bacula-sd.conf > $conf/bacula-sd$i.conf
-  mkdir -p ${working}$i
+  mkdir -p ${tmp}/$i
   sed "s/bacula-sd.conf/bacula-sd${i}.conf/" $scripts/bacula-ctl-sd \
       > $tmp/bacula-ctl-sd$i
   chmod +x $tmp/bacula-ctl-sd$i
@@ -39,7 +46,7 @@ print;
 ' $conf/bacula-dir.conf > $tmp/1
 cp $tmp/1 $conf/bacula-dir.conf
 
-disable_pluguins
+disable_plugins
 
 echo "${cwd}/build" >${cwd}/tmp/file-list
 
@@ -51,6 +58,8 @@ for sd in 2 3 4; do
   $tmp/bacula-ctl-sd$sd stop &> /dev/null
 done
 
+sleep 2
+
 # Start SDs
 for sd in 2 3 4; do
   $tmp/bacula-ctl-sd$sd start &> /dev/null
@@ -107,7 +116,7 @@ messages
 run level=Incremental storage=File2 job=$JobName yes
 wait
 messages
-@exec "touch $cwd/build/po/sv.po"
+@exec "touch $cwd/build/po/sv.po $cwd/build/po/test.po"
 run level=Incremental storage=File3 job=$JobName yes
 wait
 messages
@@ -133,7 +142,7 @@ wait
 messages
 @# run a job that will wait for a volume
 @$out ${cwd}/tmp/log23.out
-@exec "touch $cwd/build/po/Changelog"
+@exec "touch $cwd/build/po/ChangeLog"
 run level=Incremental pool=Special storage=File3 job=$JobName yes
 @sleep 5
 messages
@@ -145,7 +154,7 @@ status storage=File3
 @#
 setdebug trace=1 level=110 client
 setdebug trace=1 level=110 director
-restore where=${cwd}/tmp/bacula-restores select all done yes
+restore where=${cwd}/tmp/bacula-restores1 select all done yes
 @sleep 10
 messages
 status dir
@@ -158,6 +167,10 @@ sql
 select * FROM Storage;
 select VolumeName, Name, StorageId, MediaType FROM Media JOIN Storage USING (StorageId);
 
+@$out ${cwd}/tmp/log24.out
+restore where=${cwd}/tmp/bacula-restores select all done yes
+wait
+messages
 quit
 END_OF_DATA
 
@@ -179,6 +192,8 @@ cp $tmp/log22.out $tmp/log2.out
 check_two_logs
 cp $tmp/log23.out $tmp/log2.out
 check_two_logs
+cp $tmp/log24.out $tmp/log2.out
+check_two_logs
 
 check_restore_diff