3 # Copyright (C) 2000-2015 Kern Sibbald
4 # License: BSD 2-Clause; see file LICENSE-FOSS
8 # Run a simple backup of the /lib directory
15 scripts/copy-tape-confs
16 echo "/lib" >${cwd}/tmp/file-list
19 echo " === Starting lib-tape-root test ==="
23 cat <<END_OF_DATA > >${cwd}/tmp/bconcmds
26 @$out ${cwd}/tmp/log1.out
27 label storage=tape Volume=TestVolume001 slot=0
28 run job=NightlySave yes
34 @$out ${cwd}/tmp/log2.out
35 restore where=${cwd}/tmp/bacula-restores select all done
46 ${cwd}/bin/testls -e ${cwd}/scripts/exclude-usr-test lib >${cwd}/tmp/original
47 cd ${cwd}/tmp/bacula-restores
48 ${cwd}/bin/testls -e ${cwd}/scripts/exclude-usr-test lib >${cwd}/tmp/restored
50 sed s%.*lib/kbd/consolefonts$%lib/kbd/consolefonts% original >1
53 sed s%.*lib/kbd/consolefonts$%lib/kbd/consolefonts% restored >1
58 diff ${cwd}/tmp/original ${cwd}/tmp/restored 2>&1 1>/dev/nul
62 echo " ===== lib-tape-root failed!!! ===== "
63 echo " ===== lib-tape-root failed!!! ===== " >>test.out
66 echo " ===== lib-tape-root OK ===== "
67 echo " ===== lib-tape-root OK ===== " >>test.out