]> git.sur5r.net Git - bacula/bacula/blob - regress/tests/maxbytes-test
regress: add some debug to prune-copy-test
[bacula/bacula] / regress / tests / maxbytes-test
1 #!/bin/sh
2 #
3 #  Run a job with small Maximum Volume Bytes.  It should
4 #    create a lot of volumes. The test stresses auto-creation of
5 #    Volumes and restores from a lot of Volumes. Note, it creates
6 #    writes and then reads something like 110 Volumes (will vary
7 #    depending on the size of the Bacula source).
8 #
9 TestName="maxbytes-test"
10 JobName=maxbytes
11 . scripts/functions
12
13 scripts/cleanup
14 scripts/copy-test-confs
15 echo "${cwd}/build" >${cwd}/tmp/file-list
16
17 cp -f ${cwd}/bin/bacula-dir.conf ${cwd}/tmp/1
18 sed "s%# Maximum Volume Bytes%  Maximum Volume Bytes%" ${cwd}/tmp/1 >${cwd}/bin/bacula-dir.conf
19 cp -f ${cwd}/bin/bacula-dir.conf ${cwd}/tmp/1
20 sed "s%# Simple Label Format%  Label Format%" ${cwd}/tmp/1 >${cwd}/bin/bacula-dir.conf
21
22 change_jobname NightlySave $JobName
23 start_test
24
25 cat <<END_OF_DATA >${cwd}/tmp/bconcmds
26 @$out /dev/null
27 messages
28 @$out   ${cwd}/tmp/log1.out
29 @#setdebug level=100 Storage=File1
30 run job=$JobName level=Full Storage=File1 yes
31 wait
32 list volumes
33 messages
34 @# 
35 @# now do a restore
36 @#
37 @$out   ${cwd}/tmp/log2.out
38 restore where=${cwd}/tmp/bacula-restores select storage=File1
39 unmark *
40 mark *
41 done
42 yes
43 wait
44 @#reload
45 @#reload
46 messages
47 quit
48 END_OF_DATA
49
50 run_bacula
51 check_for_zombie_jobs storage=File1
52 stop_bacula
53
54 check_two_logs
55 check_restore_diff
56 end_test