Hi Arno
This has taken a while but here come mtx and bacula-sd.conf:
As to the btape test results:
I can't find my files with the results at the moment (oops...), but I have the print-outs here:
I reviewed them again (as I already did when I started with the autochanger) and there is really not a single error whatsoever.
I did the normal test for the drive as such and the test for the autochanger. Both succeded fine.
If you can find anything, answers would be very appreciated!
Thanks again + Best Regards,
Christoff Buch
[EMAIL PROTECTED] wrote on 29.06.2006 23:06:27:
> Hello,
>
> On 6/28/2006 11:23 AM, Christoff Buch wrote:
> >
> > Hello Users!
> >
> > I hope someone with autochanger expierience can help me with my
> > concerns....
> > First of all my environment:
> >
> > - bacula 1.38.9 (from source)
> > - mtx 1.2.18rel (from rpm)
> > - SuSE 9.0 Kernel 2.4.21-99
> > - Exabyte 221L TapeLibrary (21 slots in 3 Magazines, Barcodereader, 1
> > IBM Ultrium LTO-2 drive)
>
> First question: btape tests?
>
> > I don't think problem is in configure-options nor in bacula-xxx.confs
> > since backups succeed. So none of them here.
> > I just get those strange statements in log over and over again, and I'm
> > not sure wether someday this may lead to a crash.
> > Concerning the "Bad autochanger loaded drive 0 command" I guess it
> > might be a timing problem, but can't decide wether it's the mtx-changer
> > or bacula itself. Do you know anything?
> > (I'll add my mtx-changer)
>
> I can't read it as it claims to be a .doc file and I'm too lazy to read
> list mail in other formats than ASCII ;-)
>
> I think two things are most likely the reason for your problems:
> Configuration (use btape and post the SD config) and mtx-changer,
> especially concerning timing of autoloader operations.
>
> Arno
>
> > Concerning the "Unloading / Reloading tape for follow-up job": Just
> > why??? It's just sometimes happening, not each time!
> >
> > Today both happened in once, so here is the part of my log:
> >
> > JobId: 155
> > Job: Job1_____________.2006-06-27_22.12.15
> > Backup Level: Full
> > Client: "Client1" Windows Server 2003,MVS,NT 5.2.3790
> > FileSet: "FileSet1" 2006-06-13 20:16:29
> > Pool: "Daily"
> > Storage: "TapeLibrary"
> > Scheduled time: 27-Jun-2006 22:12:10
> > Start time: 27-Jun-2006 22:12:20
> > End time: 28-Jun-2006 00:55:04
> > Elapsed time: 2 hours 42 mins 44 secs
> > Priority: 10
> > FD Files Written: 3,903
> > SD Files Written: 3,903
> > FD Bytes Written: 122,954,473,051 (122.9 GB)
> > SD Bytes Written: 122,955,147,172 (122.9 GB)
> > Rate: 12592.6 KB/s
> > Software Compression: None
> > Volume name(s): TUE001L2
> > Volume Session Id: 1
> > Volume Session Time: 1151424310
> > Last Volume Bytes: 123,046,455,465 (123.0 GB)
> > Non-fatal FD errors: 0
> > SD Errors: 0
> > FD termination status: OK
> > SD termination status: OK
> > Termination: Backup OK
> >
> > 28-Jun 00:55 heem-dir: Begin pruning Jobs.
> > 28-Jun 00:55 heem-dir: No Jobs found to prune.
> > 28-Jun 00:55 heem-dir: Begin pruning Files.
> > 28-Jun 00:55 heem-dir: No Files found to prune.
> > 28-Jun 00:55 heem-dir: End auto prune.
> >
> > 28-Jun 00:55 heem-dir: Start Backup JobId 156,
> > Job2_________.2006-06-27_23.00.00
> > *28-Jun 00:55 heem-sd: 3301 Issuing autochanger "loaded drive 0" command.*
> > *28-Jun 00:55 heem-sd: 3991 Bad autochanger "loaded drive 0" command:
> > ERR=Operation not permitted.*
> > 28-Jun 00:55 heem-sd: 3301 Issuing autochanger "loaded drive 0" command.
> > 28-Jun 00:55 heem-sd: 3302 Autochanger "loaded drive 0", result is Slot 3.
> > *28-Jun 00:55 heem-sd: 3307 Issuing autochanger "unload slot 3, drive 0"
> > command.*
> > *28-Jun 00:55 heem-sd: 3304 Issuing autochanger "load slot 3, drive 0"
> > command.*
> > 28-Jun 00:56 heem-sd: 3305 Autochanger "load slot 3, drive 0", status is
> > OK.
> > 28-Jun 00:56 heem-sd: 3301 Issuing autochanger "loaded drive 0" command.
> > 28-Jun 00:56 heem-sd: 3302 Autochanger "loaded drive 0", result is Slot 3.
> > 28-Jun 00:56 heem-sd: Volume "TUE001L2" previously written, moving to
> > end of data.
> > 28-Jun 00:56 heem-sd: Ready to append to end of Volume "TUE001L2" at
> > file=124.
> > 28-Jun 01:52 heem-dir: Bacula 1.38.9 (02May06): 28-Jun-2006 01:52:29
> > JobId: 156
> > Job: Job2_________.2006-06-27_23.00.00
> > Backup Level: Full
> > Client: "Client2" i686-pc-linux-gnu,suse,9.0
> > FileSet: "FileSet2" 2006-06-15 00:45:31
> > Pool: "Daily"
> > Storage: "TapeLibrary"
> > Scheduled time: 27-Jun-2006 23:00:00
> > Start time: 28-Jun-2006 00:55:08
> > End time: 28-Jun-2006 01:52:29
> > Elapsed time: 57 mins 21 secs
> > Priority: 10
> > FD Files Written: 110,844
> > SD Files Written: 110,844
> > FD Bytes Written: 28,747,087,799 (28.74 GB)
> > SD Bytes Written: 28,768,112,206 (28.76 GB)
> > Rate: 8354.3 KB/s
> > Software Compression: None
> > Volume name(s): TUE001L2
> > Volume Session Id: 2
> > Volume Session Time: 1151424310
> > Last Volume Bytes: 151,839,027,155 (151.8 GB)
> > Non-fatal FD errors: 0
> > SD Errors: 0
> > FD termination status: OK
> > SD termination status: OK
> > Termination: Backup OK
> >
> > In the 3rd job, bacula doesen't repeat the "loaded drive 0" command even
> > though it gets an "ERR...".
> > But this time at least it doesn't unload/load the tape but goes on
> > immediately. (see below)
> > I don't understand this behaviour.
> >
> > 28-Jun 01:52 heem-dir: Start Backup JobId 157,
> > Job3________.2006-06-28_00.10.01
> > 28-Jun 01:52 heem-sd: 3301 Issuing autochanger "loaded drive 0" command.
> > 28-Jun 01:52 heem-sd: 3302 Autochanger "loaded drive 0", result is Slot 3.
> > *28-Jun 01:52 heem-sd: 3301 Issuing autochanger "loaded drive 0" command.*
> > *28-Jun 01:52 heem-sd: 3991 Bad autochanger "loaded drive 0" command:
> > ERR=Operation not permitted.*
> > *28-Jun 01:52 heem-sd: Volume "TUE001L2" previously written, moving to
> > end of data.*
> > *28-Jun 01:53 heem-sd: Ready to append to end of Volume "TUE001L2" at
> > file=153.*
> > 28-Jun 02:32 heem-dir: Bacula 1.38.9 (02May06): 28-Jun-2006 02:32:50
> > .....
> >
> >
> >
> >
> > Thanks in advance!
> >
> > Best Regards,
> >
> > i. A. Christoff Buch
> >
> > =====================================
> > [EMAIL PROTECTED]
> > +49.941.78004.607
> >
> > [EMAIL PROTECTED]
> > OneVision Software AG
> > Dr.-Leo-Ritter-Str. 9
> > D - 93049 Regensburg
> >
> >
> > ------------------------------------------------------------------------
> >
> > Using Tomcat but need to do more? Need to support web services, security?
> > Get stuff done quickly with pre-integrated technology to make yourjob easier
> > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
> > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
> >
> >
> > ------------------------------------------------------------------------
> >
> > _______________________________________________
> > Bacula-users mailing list
> > Bacula-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/bacula-users
>
> --
> IT-Service Lehmann [EMAIL PROTECTED]
> Arno Lehmann http://www.its-lehmann.de
>
> Using Tomcat but need to do more? Need to support web services, security?
> Get stuff done quickly with pre-integrated technology to make your job easier
> Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
> _______________________________________________
> Bacula-users mailing list
> Bacula-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/bacula-users
>
#!/bin/sh # # Bacula interface to mtx autoloader Adapted by Christoff Buch, OneVision Software AG, 2006-05-31 # # $Id: mtx-changer.in,v 1.21.2.7 2006/05/02 14:48:12 kerns Exp $ # # If you set in your Device resource # # Changer Command = "path-to-this-script/mtx-changer %c %o %S %a %d" # you will have the following input to this script: # # So Bacula will always call with all the following arguments, even though # in come cases, not all are used. # # mtx-changer "changer-device" "command" "slot" "archive-device" "drive-index" # $1 $2 $3 $4 $5 # # for example: # # mtx-changer /dev/sg0 load 1 /dev/nst0 0 (on a Linux system) # # will request to load the first cartidge into drive 0, where # the SCSI control channel is /dev/sg0, and the read/write device # is /dev/nst0. # # If you need to an offline, refer to the drive as $4 # e.g. mt -f $4 offline # # Many changers need an offline after (Sorry, not before?) the unload. Also many # changers need a sleep 60 after the mtx load. # # N.B. If you change the script, take care to return either # the mtx exit code or a 0. If the script exits with a non-zero # exit code, Bacula will assume the request failed. #
MTX=mtx # # log whats done # # to turn on logging, uncomment the following line #touch /usr/local/bacula/working/mtx.log # dbgfile="/usr/local/bacula/working/mtx.log" debug() { if test -f $dbgfile; then echo "`date +\"%Y%m%d-%H:%M:%S\"` $*" >> $dbgfile fi } # # Create a temporary file # make_temp_file() { TMPFILE=`mktemp /usr/local/bacula/working/mtx.XXXXXXXXXX` if test x${TMPFILE} = x; then TMPFILE="/usr/local/bacula/working/mtx.$$" if test -f ${TMPFILE}; then echo "Temp file security problem on: ${TMPFILE}" exit 1 fi fi } # # The purpose of this function to wait a maximum # time for the drive. It will # return as soon as the drive is ready, or after # waiting a maximum of 300 seconds. # Note, this is very system dependent, so if you are # not running on Linux, you will probably need to # re-write it, or at least change the grep target. # wait_for_drive() { i=0 while [ $i -le 300 ]; do # Wait max 300 seconds if mt -f $1 status | grep ONLINE >/dev/null 2>&1; then break fi debug "Device $1 - not ready, retrying..." sleep 1 i=`expr $i + 1` done } # check parameter count on commandline # check_parm_count() { pCount=$1 pCountNeed=$2 if test $pCount -lt $pCountNeed; then echo "usage: mtx-changer ctl-device command [slot archive-device drive-index]" echo " Insufficient number of arguments arguments given." if test $pCount -lt 2; then echo " Mimimum usage is first two arguments ..." else echo " Command expected $pCountNeed arguments" fi exit 1 fi } # Check for special cases where only 2 arguments are needed, # all others are a minimum of 5 # case $2 in list) check_parm_count $# 2 ;; slots) check_parm_count $# 2 ;; *) check_parm_count $# 5 ;; esac # Setup arguments ctl=$1 cmd="$2" slot=$3 device=$4 drive=$5 debug "Parms: $ctl $cmd $slot $device $drive" case $cmd in unload) debug "Doing mtx -f $ctl unload $slot $drive" # # enable the following line if you need to eject the cartridge # the following two(!)lines enabled by Christoff Buch, OneVision Software AG, 2006-05-31 mt -f $device offline sleep 10 ${MTX} -f $ctl unload $slot $drive ;; load) debug "Doing mtx -f $ctl load $slot $drive" ${MTX} -f $ctl load $slot $drive rtn=$? # # Increase the sleep time if you have a slow device # or remove the sleep and add the following: # the following line enabled by Christoff Buch, OneVision Software AG, 2006-05-31 wait_for_drive $device # the following line disabled by Christoff Buch, OneVision Software AG, 2006-05-31 # sleep 15 exit $rtn ;; list) debug "Doing mtx -f $ctl -- to list volumes" make_temp_file # Enable the following if you are using barcodes and need an inventory # OneVision Software AG, Exabyte 221L tape library doesn't need this! # Exabyte 221L scans barcodes after POST. Left as is by Christoff Buch, OneVision Software AG, 2006-05-31 # $(MTX) -f $ctl inventory ${MTX} -f $ctl status >${TMPFILE} rtn=$? cat ${TMPFILE} | grep " *Storage Element [0-9]*:.*Full" | awk "{print \$3 \$4}" | sed "s/Full *\(:VolumeTag=\)*//" cat ${TMPFILE} | grep "^Data Transfer Element [0-9]*:Full (Storage Element [0-9]" | awk '{printf "%s:%s\n",$7,$10}' rm -f ${TMPFILE} >/dev/null 2>&1 # # If you have a VXA PacketLoader and the above does not work, try # turning it off and enabling the following line. # ${MTX} -f $ctl status | grep " *Storage Element [0-9]*:.*Full" | sed "s/*Storage Element //" | sed "s/Full :VolumeTag=//" exit $rtn ;; loaded) debug "Doing mtx -f $ctl $drive -- to find what is loaded" make_temp_file ${MTX} -f $ctl status >${TMPFILE} rtn=$? cat ${TMPFILE} | grep "^Data Transfer Element $drive:Full" | awk "{print \$7}" cat ${TMPFILE} | grep "^Data Transfer Element $drive:Empty" | awk "{print 0}" rm -f ${TMPFILE} >/dev/null 2>&1 exit $rtn ;; slots) debug "Doing mtx -f $ctl -- to get count of slots" ${MTX} -f $ctl status | grep " *Storage Changer" | awk "{print \$5}" ;; esac
bacula-sd.conf
Description: Binary data
Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users