]> git.sur5r.net Git - bacula/bacula/blobdiff - regress/tests/memory-bug-tape
Make out of freespace non-fatal for removable devices -- i.e. behaves like tape
[bacula/bacula] / regress / tests / memory-bug-tape
index af3811ac1ea6233f49ad31cca1d6763849f52ebc..4729486b3c5a7c3bfe1290cb5e0eb4b862c4febc 100755 (executable)
@@ -1,4 +1,9 @@
 #!/bin/sh
+#
+# Copyright (C) 2000-2015 Kern Sibbald
+# License: BSD 2-Clause; see file LICENSE-FOSS
+#
+
 #
 # Do a whole lot of select commands. This test is one where the 
 #   Director should be run under valgrind.  This exercises SQL a bit
@@ -9,20 +14,22 @@ TestName="four-concurrent-jobs-tape"
 JobName=FourConcurrentJobs
 . scripts/functions
 
+require_tape_drive
+
 scripts/cleanup-tape
 scripts/copy-tape-confs
 
-echo "${cwd}/build" >/tmp/file-list
+echo "${cwd}/build" >${cwd}/tmp/file-list
 
 change_jobname $JobName
 start_test
 
-cat <<END_OF_DATA >tmp/bconcmds
-@output /dev/null
+cat <<END_OF_DATA >${cwd}/tmp/bconcmds
+@$out /dev/null
 messages
-@$out tmp/log1.out
-label storage=DDS-4 volume=TestVolume001 slot=0 pool=Default
-run job=$JobName level=Full Storage=DDS-4 yes
+@$out ${cwd}/tmp/log1.out
+label storage=tape volume=TestVolume001 slot=0 pool=Default
+run job=$JobName level=Full Storage=tape yes
 sql
 SELECT * from File;
 SELECT * from File;
@@ -20030,27 +20037,26 @@ SELECT * FROM Media;
 status dir
 @sleep 5
 status dir
-status storage=DDS-4
+status storage=tape
 messages
 wait
 messages
 @# 
 @# now do a restore
 @#
-@$out tmp/log2.out
-restore where=${cwd}/tmp/bacula-restores select storage=DDS-4
+@$out ${cwd}/tmp/log2.out
+restore where=${cwd}/tmp/bacula-restores select storage=tape
 unmark *
 mark *
 done
 yes
 wait
 messages
-@$out
 quit
 END_OF_DATA
 
 run_bacula
-check_for_zombie_jobs storage=DDS-4
+check_for_zombie_jobs storage=tape
 stop_bacula
 
 check_two_logs