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