3 # Run two jobs at the same time
6 scripts/copy-test-confs
8 echo "${cwd}/tmp/largefile" >/tmp/file-list
9 # Create 56MB file with random data
10 echo "Creating a 56MB file with random data ..."
11 dd if=/dev/urandom of=${cwd}/tmp/largefile bs=1024 count=55000
12 echo "largefile created"
13 bin/bacula stop 2>&1 >/dev/null
14 bin/drop_sqlite_tables
15 bin/make_sqlite_tables
19 echo " === Starting concurrent-jobs-test ==="
20 echo " === Starting concurrent-jobs-test ===" >>working/log
23 bin/bacula start 2>&1 >/dev/null
24 bin/console -c bin/console.conf <<END_OF_DATA
30 run job=CompressedTest level=Full
32 run job=CompressedTest level=Full
34 run job=CompressedTest level=Full
36 run job=CompressedTest level=Full
44 restore where=${cwd}/tmp/bacula-restores
54 bin/bacula stop 2>&1 >/dev/null
55 grep "^Termination: *Backup OK" tmp/log1.out 2>&1 >/dev/null
57 grep "^Termination: *Restore OK" tmp/log2.out 2>&1 >/dev/null
59 diff tmp/largefile tmp/bacula-restores${cwd}/tmp/largefile
60 if [ $? != 0 -o $bstat != 0 -o $rstat != 0 ] ; then
63 echo " !!!!! concurrent-jobs-test Bacula source failed!!! !!!!! "
64 echo " !!!!! concurrent-jobs-test failed!!! !!!!! " >>test.out
67 echo " ===== concurrent-jobs-test Bacula source OK ===== "
68 echo " ===== concurrent-jobs-test OK ===== " >>test.out