3 # Cleanup left over files -- both before and after test run
7 if test ! x@autochanger@ = x/dev/null; then
8 slot=`bin/mtx-changer @autochanger@ loaded 0 @tape_drive1@ 1`
9 echo "Slot $slot in drive 1"
10 if test ! x$slot = x0 ; then
11 echo "unload slot $slot in drive 1"
12 bin/mtx-changer @autochanger@ unload $slot @tape_drive1@ 1
14 slot=`bin/mtx-changer @autochanger@ loaded 0 @tape_drive@ 0`
15 echo "Slot $slot in drive 0"
16 if test ! x$slot = x0 ; then
17 echo "unload slot $slot in drive 0"
18 bin/mtx-changer @autochanger@ unload $slot @tape_drive@ 0
22 slot=`bin/mtx-changer @autochanger@ loaded 0 @tape_drive1@ 1`
23 if test ! x$slot = x2; then
24 echo "load slot 2 in drive 1"
25 bin/mtx-changer @autochanger@ load 2 @tape_drive1@ 1
28 mt -f @tape_drive1@ rewind
29 mt -f @tape_drive1@ weof
30 echo "unload slot 2 in drive 1"
31 bin/mtx-changer @autochanger@ unload 2 @tape_drive1@ 1
33 slot=`bin/mtx-changer @autochanger@ loaded 0 @tape_drive@ 0`
34 echo "Slot $slot in drive 0"
35 if test ! x$slot = x1; then
36 echo "load slot 1 in drive 0"
37 bin/mtx-changer @autochanger@ load 1 @tape_drive@ 0
40 mt -f @tape_drive@ rewind
41 mt -f @tape_drive@ weof
42 echo "unload slot 1 from drive 0"
43 bin/mtx-changer @autochanger@ unload 1 @tape_drive@ 0