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