3 # Run a simple backup of the Bacula build directory
8 echo " === /lib save/restore test ==="
12 if [ $UID != 0 ] ; then
14 echo "You must be root to run this test."
15 echo " ===== Test5 failed!!! ===== "
16 echo " ===== Test5 failed!!! ===== " >>test.out
21 scripts/copy-test-confs
22 echo "/lib" >/tmp/file-list
23 rm -rf /tmp/TestVolume001 /tmp/bacula-restores
24 bin/bacula stop 2>&1 >/dev/null
25 bin/drop_sqlite_tables
26 bin/make_sqlite_tables
27 bin/bacula start 2>&1 >/dev/null
28 bin/console -c bin/console.conf <<END_OF_DATA
50 bin/bacula stop 2>&1 >/dev/null
52 ${cwd}/bin/testls -e ${cwd}/scripts/exclude-lib-test lib >${cwd}/tmp/original
53 cd /tmp/bacula-restores
54 ${cwd}/bin/testls -e ${cwd}/scripts/exclude-lib-test lib >${cwd}/tmp/restored
55 diff ${cwd}/tmp/original ${cwd}/tmp/restored 2>&1 >/dev/null
59 echo " ===== Test5 /lib failed!!! ===== "
60 echo " ===== Test5 failed!!! ===== " >>test.out
63 echo " ===== Test5 /lib OK ===== "
64 echo " ===== Test5 OK ===== " >>test.out