3 # Copyright (C) 2000-2017 Kern Sibbald
4 # License: BSD 2-Clause; see file LICENSE-FOSS
7 # Try to stress test autolabel by creating lots of new
8 # volumes. This is to try to show up a bug 8103 where
9 # at some point a volume is created in the catalog but
10 # not labeled, and then produces errors.
13 TestName="auto-label-many-test"
19 echo "${cwd}/build" >${cwd}/tmp/file-list
21 cp ${cwd}/bin/bacula-dir.conf ${cwd}/tmp/1
22 sed "s%# Simple Label Format% Label Format%" ${cwd}/tmp/1 >${cwd}/bin/bacula-dir.conf
23 cp ${cwd}/bin/bacula-dir.conf ${cwd}/tmp/1
24 sed "s%# Maximum Volume% Maximum Volume%g" ${cwd}/tmp/1 >${cwd}/bin/bacula-dir.conf
26 change_jobname CompressedTest $JobName
29 #$bperl -e 'add_attribute("$conf/bacula-dir.conf", "SpoolData", "no", "Job")'
30 #$bperl -e 'add_attribute("$conf/bacula-sd.conf", "Upload", "no", "Cloud")'
32 cat <<END_OF_SCRIPT >${cwd}/tmp/bconcmds
35 @$out ${cwd}/tmp/log1.out
37 setdebug level=200 trace=1 options=hT storage=File
38 @#setdebug level=50 dir
39 run job=$JobName level=Full storage=File yes
40 run job=$JobName storage=File yes
41 run job=$JobName level=Full storage=File yes
42 run job=$JobName storage=File yes
43 @#run job=$JobName storage=File yes
44 @#run job=$JobName storage=File yes
45 @#run job=$JobName storage=File yes
53 @$out ${cwd}/tmp/log2.out
54 setdebug level=0 storage=File
56 restore where=${cwd}/tmp/bacula-restores select storage=File
63 @# Now restore JobId=1
64 restore where=${cwd}/tmp/bacula-restores storage=File
72 @# Now restore JobId=3
73 restore where=${cwd}/tmp/bacula-restores storage=File
85 check_for_zombie_jobs storage=File