]> git.sur5r.net Git - bacula/bacula/blob - regress/tests/verify-vol-test
Add some debug info
[bacula/bacula] / regress / tests / verify-vol-test
1 #!/bin/sh
2 #
3 # Run a simple backup of the Bacula build directory
4 #   then verify the catalog.           
5 #
6 TestName="verify-vol-test"
7 JobName=VerifyVol
8 . scripts/functions
9 set_debug 0
10
11 cwd=`pwd`
12 scripts/cleanup
13 scripts/copy-test-confs
14 echo "${cwd}/build" >/tmp/file-list
15
16 change_jobname NightlySave $JobName
17 start_test
18
19 cat <<END_OF_DATA >tmp/bconcmds
20 @$out /dev/null
21 messages
22 @$out tmp/log1.out
23 setdebug level=1 storage=File sd
24 label storage=File volume=TestVolume001
25 run job=$JobName yes
26 wait
27 messages
28 @# 
29 @# now do a verify volume
30 @#
31 @$out ${cwd}/tmp/original
32 run job=VerifyVolume
33 yes
34 wait
35 messages
36 @$out
37 quit
38 END_OF_DATA
39
40 run_bacula
41
42 sleep 2
43 check_for_zombie_jobs storage=File 
44 stop_bacula
45
46 grep "^  Termination: *Backup OK" tmp/log1.out 2>&1 >/dev/null
47 bstat=$?
48 grep "^  Termination: *Verify OK" ${cwd}/tmp/original 2>&1 >/dev/null
49 rstat=$?
50 dstat=0
51 end_test