3 # Run a job with a limited tape size so that the tape fills up.
4 # Then manually unload the tape and load a new one, label
7 TestName="two-vol-manual-tape"
8 JobName=twovolmanualtape
15 scripts/copy-tape-confs
16 echo "${cwd}/build" >${cwd}/tmp/file-list
17 MTX=$AUTOCHANGER_SCRIPT
19 # Sleep longer if real tape
20 if [ x${USE_VTAPE} = xyes ] ; then
30 init_slot $TAPE_DRIVE $SLOT1
31 init_slot $TAPE_DRIVE $SLOT2
33 # Get a tape from slot1
34 slot=`bin/$MTX ${AUTOCHANGER} loaded 0 ${TAPE_DRIVE} $DRIVE1`
37 bin/$MTX ${AUTOCHANGER} load $SLOT1 ${TAPE_DRIVE} $DRIVE1
44 rewind_drive ${TAPE_DRIVE}
45 bin/$MTX ${AUTOCHANGER} unload $slot ${TAPE_DRIVE} $DRIVE1
46 bin/$MTX ${AUTOCHANGER} load $SLOT1 ${TAPE_DRIVE} $DRIVE1
51 init_drive ${TAPE_DRIVE}
53 change_jobname $JobName
57 cat <<END_OF_DATA >tmp/bconcmds
61 label storage=DDS-4 volume=TestVolume002 slot=0 pool=Default drive=0
68 init_drive ${TAPE_DRIVE}
70 # label first volume, and run first half of job
71 cat <<END_OF_DATA >tmp/bconcmds
73 label storage=DDS-4 volume=TestVolume001 slot=0 pool=Default drive=0
74 update Volume=TestVolume001 MaxVolBytes=500000 pool=Default drive=0
76 setdebug level=150 storage=DDS-4
78 @# This sleep must be long enough for the first tape to fill (4MB)
79 @# otherwise the following mtx-changer commands will fail
92 init_drive ${TAPE_DRIVE}
94 cat <<END_OF_DATA >tmp/bconcmds
96 @# backup should continue
101 @#restore where=${cwd}/tmp/bacula-restores select all storage=DDS-4 done
110 # run second half of backup + restore
115 check_for_zombie_jobs storage=DDS-4