3 # Run two jobs at the same time
6 TestName="concurrent-jobs-test"
7 JobName=concurrent-jobs
13 echo "${cwd}/tmp/largefile" >/tmp/file-list
14 if test -c /dev/urandom ; then
15 # Create 56MB file with random data
16 echo "Creating a 56MB file with random data ..."
17 dd if=/dev/urandom of=${cwd}/tmp/largefile bs=1024 count=55000
19 echo "Creating a 56MB file with bacula-dir data ..."
20 dd if=bin/bacula-dir of=${cwd}/tmp/1 bs=1024 count=1000
21 cat ${cwd}/tmp/1 ${cwd}/tmp/1 ${cwd}/tmp/1 ${cwd}/tmp/1 ${cwd}/tmp/1 >${cwd}/tmp/2
23 cat ${cwd}/tmp/2 ${cwd}/tmp/2 ${cwd}/tmp/2 ${cwd}/tmp/2 ${cwd}/tmp/2 >>${cwd}/tmp/3
25 cat ${cwd}/tmp/3 ${cwd}/tmp/3 ${cwd}/tmp/3 ${cwd}/tmp/3 ${cwd}/tmp/3 >${cwd}/tmp/largefile
29 echo "largefile created"
31 change_jobname CompressedTest $JobName
34 cat <<END_OF_DATA >tmp/bconcmds
38 label storage=File volume=TestVolume001
39 run job=$JobName level=Full yes
40 run job=$JobName level=Full yes
41 run job=$JobName level=Full yes
42 run job=$JobName level=Full yes
49 restore where=${cwd}/tmp/bacula-restores select storage=File
61 check_for_zombie_jobs storage=File
65 diff tmp/largefile tmp/bacula-restores${cwd}/tmp/largefile 2>&1 >/dev/null