At 14:54 2005-06-07, Thomas Sturm wrote:

Hello BACULA-users,
I have a problem withe my autochanger-device:
for some unknown reason, sometimes the autochanger-command work and later
in the same backup-job they fail. See log-file:

06-Jun 23:22 bacula-sd: 3301 Issuing autochanger "loaded drive 0" command.
06-Jun 23:22 bacula-sd: 3302 Autochanger "loaded drive 0", result is Slot 2.
06-Jun 23:22 bacula-sd: 3303 Issuing autochanger "unload slot 2, drive 0 "command. 06-Jun 23:23 bacula-sd: 3304 Issuing autochanger "load slot 3, drive 0" command.
06-Jun 23:24 bacula-sd: 3305 Autochanger "load slot 3, drive 0", status is OK.
07-Jun 04:47 bacula-sd: 3301 Issuing autochanger "loaded drive 0" command.
07-Jun 04:47 bacula-sd: 3302 Autochanger "loaded drive 0", result is Slot 3.
07-Jun 04:47 bacula-sd: 3303 Issuing autochanger "unload slot 3, drive 0" command. 07-Jun 04:48 bacula-sd: 3304 Issuing autochanger "load slot 4, drive 0" command.
07-Jun 04:50 bacula-sd: 3305 Autochanger "load slot 4, drive 0", status is OK.
07-Jun 12:23 bacula-sd: 3301 Issuing autochanger "loaded drive 0" command.
07-Jun 12:23 bacula-sd: 3991 Bad autochanger "loaded drive 0" command: ERR=Child exited with code 1. 07-Jun 12:23 bacula-sd: 3304 Issuing autochanger "load slot 6, drive 0" command. 07-Jun 12:25 bacula-sd: 3992 Bad autochanger "load slot 6, drive 0": ERR=Child exited with code 1.

What I do then is to issue the mtx-changer commands manually from linux-console (and they work!)
and to do a mount in bacula-console. The backup-job then will continue.

Does anyone know what is going on?

The 'mtx' command isn't very robust (to say the least - it's a horribly hack - not Bacula quality at all, but then it's not written by Kern et al either :-). It's extremely sensitive for SCSI errors/warnings/notifications from
the tape robot and will fail operations for seemingly stupid reasons.

For exampel, our hardware - a Sun StorEdge L11000 (a rebadge engineered ATL P3000 with 6 tape drives and 384 tape slots) will cause SCSI notifications to be posted when we open the doors to it to insert tapes - this will cause the next MTX command to fail (even though the SCSI notification only says "door was opened" (or similar), ie a purely
informational message).

This failure isn't always noticed though since some MTX commands does an internal operation first where it queries the robot for it's configuration - and if that one fails it falls back to some defaults (1 tape drive & 64 slots or something similar) which works in most cases - if your robot has one tape drive and less than (or equal to) 64 slots, but really fails for large robots...

Other cases where MTX will fail is if the robot decides it's time to run a cleaning tape - this typically happens when you load or unload a tape - and MTX tries to load a tape into a drive that is busy cleaning...

Check you system logs for any SCSI related messages (dunno if Linux prints then, but my Solaris system
prints them nicely).

Anyway - to make things a bit more robust I've written a MTX replacement that I've called "PJC" (Peter's Jukebox Controller) that tries to be more resilient against these types of problems. Since switching to PJC I've seem much fewer errors
from Bacula.

I haven't really tested it on Linux though (but I've compiled it atleast). In case someone is interrested in trying it you can
FTP the source code from:

   ftp://ftp.lysator.liu.se/pub/unix/pjc

It comes complete with a "pjc-changer" script that can be used instead of the Bacula "mtx-changer" script.

- Peter



--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.323 / Virus Database: 267.6.2 - Release Date: 2005-06-04




-------------------------------------------------------
This SF.Net email is sponsored by: NEC IT Guy Games.  How far can you shotput
a projector? How fast can you ride your desk chair down the office luge track?
If you want to score the big prize, get to know the little guy. Play to win an NEC 61" plasma display: http://www.necitguy.com/?r=20
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users

Reply via email to