]> git.sur5r.net Git - bacula/bacula/blob - bacula/examples/autochangers/mtx-changer.Adic-Scalar-100
Make out of freespace non-fatal for removable devices -- i.e. behaves like tape
[bacula/bacula] / bacula / examples / autochangers / mtx-changer.Adic-Scalar-100
1 From bacula-users-admin@lists.sourceforge.net Wed Dec 10 15:04:47 2003
2 Return-Path: <bacula-users-admin@lists.sourceforge.net>
3 Received: from sc8-sf-mx1.sourceforge.net (lists.sourceforge.net
4         [66.35.250.206]) by matou.sibbald.com (8.11.6/8.11.6) with ESMTP id
5         hBAE4lY32735 for <kern@sibbald.com>; Wed, 10 Dec 2003 15:04:47 +0100
6 Received: from sc8-sf-list2-b.sourceforge.net ([10.3.1.8]
7         helo=sc8-sf-list2.sourceforge.net) by sc8-sf-mx1.sourceforge.net with esmtp
8         (TLSv1:AES256-SHA:256) (Exim 4.24) id 1AU4wc-0007gs-Ls; Wed, 10 Dec 2003
9         06:04:02 -0800
10 Received: from localhost.localdomain ([127.0.0.1]
11         helo=projects.sourceforge.net) by sc8-sf-list2.sourceforge.net with esmtp
12         (Exim 4.24) id 1AU4wc-0006AC-FQ; Wed, 10 Dec 2003 06:04:02 -0800
13 Received: from sc8-sf-mx2-b.sourceforge.net ([10.3.1.12]
14         helo=sc8-sf-mx2.sourceforge.net) by sc8-sf-list2.sourceforge.net with esmtp
15         (Exim 4.24) id 1AU4vz-00068m-GL for bacula-users@lists.sourceforge.net;
16         Wed, 10 Dec 2003 06:03:23 -0800
17 Received: from mta2.navair.navy.mil ([192.58.199.164]) by
18         sc8-sf-mx2.sourceforge.net with esmtp (Exim 4.24) id 1AU4vy-0006U5-2Q for
19         bacula-users@lists.sourceforge.net; Wed, 10 Dec 2003 06:03:22 -0800
20 Received: by mta2.navair.navy.mil (Postfix, from userid 0) id EEB0B16C1FD;
21         Wed, 10 Dec 2003 09:03:10 -0500 (EST)
22 Received: from neim02.nawcad.navy.mil (neim02.nawcad.navy.mil
23         [140.229.37.205]) by mta2.navair.navy.mil (Postfix) with ESMTP id
24         64D5116C2A9; Wed, 10 Dec 2003 09:03:10 -0500 (EST)
25 Received: by neim02.nawcad.navy.mil with Internet Mail Service
26         (5.5.2657.72) id <YQB85LRX>; Wed, 10 Dec 2003 09:02:18 -0500
27 Message-ID: <B9500E218FB4D2119DE30000F810BBBF0486F1B9@nems13.nawcad.navy.mil>
28 From: "Kirkpatrick, Drew  (ARINC)" <KirkpatricDA@navair.navy.mil>
29 To: "'terry@mrtux.co.uk'" <terry@mrtux.co.uk>, bacula-users@lists.sourceforge.net
30 Subject: RE: [Bacula-users] Re: Autochanger setup
31 MIME-Version: 1.0
32 X-Mailer: Internet Mail Service (5.5.2657.72)
33 Content-Type: text/plain; charset="ISO-8859-1"
34 X-Spam-Score: 0.0 (/)
35 X-Spam-Report: Spam Filtering performed by sourceforge.net. See
36         http://spamassassin.org/tag/ for more details. Report problems to
37         https://sf.net/tracker/?func=add&group_id=1&atid=200001 0.0 CLICK_BELOW    
38                Asks you to click below
39 Sender: bacula-users-admin@lists.sourceforge.net
40 Errors-To: bacula-users-admin@lists.sourceforge.net
41 X-BeenThere: bacula-users@lists.sourceforge.net
42 X-Mailman-Version: 2.0.9-sf.net
43 Precedence: bulk
44 List-Unsubscribe:
45         <https://lists.sourceforge.net/lists/listinfo/bacula-users>,
46         <mailto:bacula-users-request@lists.sourceforge.net?subject=unsubscribe>
47 List-Id: Bacula user's email list for support and discussions
48         <bacula-users.lists.sourceforge.net>
49 List-Post: <mailto:bacula-users@lists.sourceforge.net>
50 List-Help: <mailto:bacula-users-request@lists.sourceforge.net?subject=help>
51 List-Subscribe:
52         <https://lists.sourceforge.net/lists/listinfo/bacula-users>,
53         <mailto:bacula-users-request@lists.sourceforge.net?subject=subscribe>
54 List-Archive:
55         <http://sourceforge.net/mailarchive/forum.php?forum=bacula-users>
56 Date: Wed, 10 Dec 2003 09:02:14 -0500
57 X-Spam-Score: 0.0 (/)
58 X-Spam-Report: Spam Filtering performed by sourceforge.net. See
59         http://spamassassin.org/tag/ for more details. Report problems to
60         https://sf.net/tracker/?func=add&group_id=1&atid=200001 0.0 CLICK_BELOW    
61                Asks you to click below
62 Status: RO
63 X-Status: F
64 X-Keywords:                
65 X-UID: 76
66 Content-Transfer-Encoding: 8bit
67
68 So far this seems to be working for me, but it's not all quite finished :)
69
70 Device {
71         Name = "firstTapeDrive"
72         Media Type = AIT3
73         Archive Device = /dev/nst0
74         Changer Device = /dev/sg3
75         Changer Command = "/etc/bacula/mtx-changer %c %o %S %a"
76         AutoChanger = yes
77         Backward Space Record = no
78         RemovableMedia = yes
79         AlwaysOpen = yes
80         AutomaticMount = yes
81         LabelMedia = no
82 #       HardwareEndOfMedium = no
83 }
84
85
86
87 And here's the current version of my mtx-changer script (which changes
88 frequently as I figure out more of this stuff)
89
90 ****************************************************************************
91 **********************
92
93 #!/bin/bash
94
95 # mtx-changer script modded to work with a Adic Scalar 100 better
96 # Drew Kirkpatrick, kirkpatricda@navair.navy.mil
97
98
99 echo "mtx-change called with: "$@
100
101
102 AUTOLOADERDEV=$1
103 DRIVE=0
104 DRIVE_0_SEARCH="Data Transfer Element 0"
105 DRIVE_1_SEARCH="Data Transfer Element 1"
106 MTX=/usr/local/sbin/mtx
107
108
109
110
111 ######################### Functions
112
113 TMPDIR=/tmp
114
115 make_temp_file() 
116 {
117   TMPFILE=`mktemp ${TMPDIR}/mtx$1.XXXXXXXXXX 2> /dev/null`
118   if test $? -ne 0 || test x${TMPFILE} = x; then
119      TMPFILE="${TMPDIR}/mtx$1.$$"
120      if test -f ${TMPFILE}; then
121         echo "ERROR: Temp file security problem on: ${TMPFILE}"
122         exit 1
123      fi
124   fi
125 }
126
127
128
129
130
131 # Take a single argument, a barcode number
132 # and returns the slot in which said tape
133 # should reside according to the 
134 # tapeSlotMap file. That file is
135 # created using the setTapeSlotMap
136 # script
137 getSlotNum()
138 {
139     if [ -z "$1" ]
140         then
141             echo getSlotNum"() called" \
142             "without a parameter, error!!!"
143             exit 1
144     fi
145     
146 # makes sure there is an entry in .tapeSlotMap file
147 # for that barcode number
148     found=`grep "$1" /etc/bacula/.tapeSlotMap | wc -l | awk '{print $1}'`
149
150     if [ "$found" -ne 1 ]
151     then
152         echo "FATAL ERROR, in getSlotNum($1), error looking up" 
153         echo "that barcode number. Found ($found) instances in the" 
154         echo "tapeSlotMap file. There should be 1 instance. Do you" 
155         echo "need to update this file with setTapeSlotMap script???"
156         exit 1
157     fi
158
159     slotNum=`grep "$1" /etc/bacula/.tapeSlotMap | awk '{print $1}'`
160     return $slotNum
161 }
162
163
164
165
166
167
168 # Take 1 arg, a 0 or 1 (or, how about the DRIVE var: )
169 # for the drive it is interested in
170 # returns 1 if that drive has a tape loaded, and 0 if not
171 doesDriveGottaTape() 
172 {
173     if [ -z "$1" ]
174         then
175             echo "doesDriveGottaTape() called" \
176             "without a parameter, error fool!!!"
177             exit 1
178         else
179             case "$1" in
180                 0 )
181                     ANSWER=`${MTX} -f $AUTOLOADERDEV status | grep
182 "$DRIVE_0_SEARCH" \
183                         | awk '{sub("0:",""); print $4}'`
184                 ;;
185                 1 )
186                     ANSWER=`${MTX} -f $AUTOLOADERDEV status | grep
187 "$DRIVE_1_SEARCH" \
188                         | awk '{sub("1:",""); print $4}'`
189                 ;;
190                 * )
191                     echo "Invalid drive num passed to
192 doesDriveGottaTape($1)"
193                     exit 1
194                 ;;
195             esac
196     fi
197     
198     case "$ANSWER" in
199         Full )
200             return 1
201         ;;
202         Empty )
203             return 0
204         ;;
205         * )
206             echo "Fatal error, invalid answer in doesDriveGottaTape(),
207 $ANSWER"
208             exit 1
209         ;;
210     esac        
211 }
212
213
214
215
216
217
218 # This handles 'correctly' unloading a drive to make sure it ends up 
219 # in the slot it originaly came from. If you're moving/adding tapes
220 # please check the setTapeSlotMap script, and use accordingly 
221 # to update the barcode->slot mappings.
222 # This function is needed because the Adic Scalar 100 
223 # doesn't seem to like returning a tape to it's original slot
224 # everytime. It seems to pick the first available, and I can't
225 # seem to figure out how to make it stop doing this. 
226 # oh, and it takes 1 arg, the drive to unload
227 unloadDrive()
228 {
229     if [ -z "$1" ]
230         then
231             echo "unloadDrive() called " \
232             "without a parameter, error!!!"
233             exit 1
234     fi
235
236
237 # double check to see if that drive does actually have a tape in it
238     doesDriveGottaTape "$1"
239     rtn=$?
240     if [ "$rtn" == 0 ]
241     then
242         echo "errrm, in unloadDrive($1), that drive " \
243             "doesn't have a tape in it!!!"
244         return 0
245     fi
246
247     
248 # Get the barcode of the tape in the drive
249     case "$1" in
250         0 )
251             barcode=`${MTX} -f $AUTOLOADERDEV status | grep
252 "$DRIVE_0_SEARCH" | awk '{print $10}'`
253         ;;
254         1 )
255             barcode=`${MTX} -f $AUTOLOADERDEV status | grep
256 "$DRIVE_1_SEARCH" | awk '{print $10}'`
257         ;;
258         * )
259             echo "ERROR, invalid drive num in unloadDrive($1)"
260             exit 1
261         ;;
262     esac
263
264 # return tape with barcode to which slot???
265     getSlotNum "$barcode"
266     returnTo=$?
267
268
269 # unloading the tape now
270     ${MTX} -f $AUTOLOADERDEV unload $returnTo $1
271     rtn=$?
272     if [ "$rtn" -ne 0 ]
273     then
274         echo "MTX came back with code ($rtn)"
275         echo "ERROR, in unloadDrive($1), mtx unload failed"
276         exit 1
277     fi
278     return $rtn
279 }
280
281
282
283
284 # This handles loading tapes into drives
285 # It checks if there is currently a tape
286 # in the target drive, and if there is 
287 # it unloads it prior to loading the new tape
288 # just in case bacula doesn't explicitly 
289 # request this. 
290 # This function take two args, the drive
291 # to load, and the tape slot to load from
292 loadDrive()
293 {
294     if [ -z "$1" ] || [ -z "$2" ]
295     then
296         echo "loadDrive() not called " \
297             "with the correct params, error!!!"
298             exit 1
299     fi
300     
301 # Check to see if it already has a tape in it...
302     doesDriveGottaTape "$1"
303     rtn=$?
304     if [ "$rtn" == 1 ]
305     then
306         echo "Oops, in loadDrive() that drive"
307         echo "already has a tape. Unloading it now"
308         unloadDrive "$1"
309     fi
310
311
312 # You're now ready to load the drive
313     echo "Now loading tape in slot $2 into drive $1"
314
315     ${MTX} -f $AUTOLOADERDEV load $2 $1
316     rtn=$?
317     if [ "$rtn" -ne 0 ]
318     then
319         echo "MTX came back with code ($rtn)"
320         echo "ERROR, in loadDrive($1, $2), mtx load failed"
321         exit 1
322     fi
323     return $rtn
324 }
325
326
327
328
329
330 #######################    End Functions
331
332
333
334
335 #######################    Start Script
336
337 # Changes the nst* device bacula passes to a number that mtx likes
338 if [ "$2" == load ] || [ "$2" == unload ]
339 then
340     echo "In mtx-changer drive selection code...."
341     case "$4" in
342         /dev/nst0 )
343             DRIVE="0"
344         ;;
345
346         /dev/nst1 )
347             DRIVE="1"
348         ;;
349
350         * )
351             echo "Error, invalid drive for autoloader."
352             echo "Maybe you mispelled the drive name, or tried to"
353             echo "use a drive that doesn't exist"
354             echo "Only two drives handled in /etc/bacula/mtx-changer script"
355             exit 1
356         ;;
357     esac
358 fi
359
360
361
362
363 case "$2" in 
364    unload)
365         unloadDrive "$DRIVE"
366         rtn=$?
367         
368         sleep 35
369         exit $rtn
370       ;;
371
372    load)
373         loadDrive "$DRIVE" "$3"
374         rtn=$?
375         sleep 55
376         exit $rtn
377       ;;
378
379    list) 
380       echo "Requested list, DREW YOU HAVEN'T IMPLEMENTED YET!!!!"
381       ${MTX} -f $1 status | grep " *Storage Element [0-9]*:.*Full" |  \
382         awk "{print \$3 \$4}" | sed "s/Full *\(:VolumeTag=\)*//"
383
384       rtn=$?
385       echo "mtx-changer returning value: $rtn"
386       ;;
387
388    loaded)
389       echo "Request loaded, DREW YOU HAVEN'T IMPLEMENTED YET!!!!"
390       make_temp_file
391       ${MTX} -f $1 status >${TMPFILE}
392       rtn=$?
393       cat ${TMPFILE} | grep "^Data Transfer Element 0:Full" | awk "{print
394 \$7}"
395       cat ${TMPFILE} | grep "^Data Transfer Element 0:Empty" | awk "{print
396 0}"
397 #       cat ${TMPFILE} | grep "^Data Transfer Element 1:Full" | awk "{print
398 \$7}"
399 #       cat ${TMPFILE} | grep "^Data Transfer Element 1:Empty" | awk
400 "{print 0}"
401       rm -f ${TMPFILE}
402
403       echo "mtx-changer returning value: $rtn"
404       exit $rtn
405       ;;
406
407    slots)
408      echo "Request slots, DREW YOU HAVEN'T IMPLEMENTED YET!!!!"
409       ${MTX} -f $1 status | grep " *Storage Changer" | awk "{print \$5}"
410       rtn=$?
411       echo "mtx-changer returning value: $rtn"
412       ;;
413 esac
414
415
416 ****************************************************************************
417 **
418
419
420
421
422
423 Hope that helps. Sorry, it's kinda setup for our Adic, and for two drives. 
424
425
426
427 -Drew
428
429
430 -----Original Message-----
431 From: Terry [mailto:terry@mrtux.co.uk]
432 Sent: Wednesday, December 10, 2003 8:23 AM
433 To: bacula-users@lists.sourceforge.net
434 Subject: [Bacula-users] Re: Autochanger setup
435
436
437 bacula-users-request@lists.sourceforge.net wrote:
438
439 >Send Bacula-users mailing list submissions to
440 >       bacula-users@lists.sourceforge.net
441 >
442 >To subscribe or unsubscribe via the World Wide Web, visit
443 >       https://lists.sourceforge.net/lists/listinfo/bacula-users
444 >or, via email, send a message with subject or body 'help' to
445 >       bacula-users-request@lists.sourceforge.net
446 >
447 >You can reach the person managing the list at
448 >       bacula-users-admin@lists.sourceforge.net
449 >
450 >When replying, please edit your Subject line so it is more specific
451 >than "Re: Contents of Bacula-users digest..."
452 >
453 >
454 >Today's Topics:
455 >
456 >   1. Two beta releases (Kern Sibbald)
457 >   2. Re: Current Volume "Cinta-0006" not acceptable
458 >       because (Kern Sibbald)
459 >   3. Re: Jobs awaiting execution? (Kern Sibbald)
460 >   4. Re: Mount need for every job... me too (Gregory Brauer)
461 >   5. Importtant: BIG Problems with schedule / bacula doesn't do
462 Differnetial
463 >       backups (Volker Sauer)
464 >   6. Re: Mount need for every job... me too (fixed!) (Gregory Brauer)
465 >
466 >--__--__--
467 >
468 >Message: 1
469 >From: Kern Sibbald <kern@sibbald.com>
470 >To: bacula-announce <bacula-announce@lists.sourceforge.net>
471 >Cc: bacula-users <bacula-users@lists.sourceforge.net>
472 >Organization: 
473 >Date: 09 Dec 2003 22:11:47 +0100
474 >Subject: [Bacula-users] Two beta releases
475 >
476 >Hello,
477 >
478 >I have just made two Beta releases. Unfortunately, I mistakenly put the
479 >1.32e-08Dec03 Windows binaries in main win-binaries section rather than
480 >win-binaries-beta. At this point, I won't change it because it would
481 >require a new upload, ...
482 >
483 >The 1.33-08Dec03 release is definitely a Beta release in the sense that
484 >version 1.33 is still under very active development.  The main features
485 >of this release are: 
486 >- all features in 1.32e-08Dec03
487 >- update slots (marks any other Volumes in the same pool with the same
488 >  Slot number as "not InChanger"). This permits retaining the Slot on
489 >  Volumes not currently in the magazine.
490 >- update slots=<slot1>,<slot2>,<slot-range>, ...
491 >  where slot1, slot2 are slot numbers you want updated from barcode
492 >  information and slot-range is a slot-number1-slot-number2 (e.g. 3-5).
493 >- update slots[=...] scan
494 >  causes the Storage daemon to read the volume label for each slot 
495 >  listed, or in the absence of a slot list, all slots occupied.
496 >- Automatic synchronization of clocks between DIR and FD so that there
497 >  is no missed files due to timezone differences or shewed clocks.
498 >- A database upgrade is mandatory.
499 >- None of the daemons are compatible with version 1.32x, which means
500 >  you must upgrade all or nothing.
501 >- NOTE! FreeBSD users must add:
502 >   Two EOF = yes
503 >  to each of their tape Device resources in the SD. I forgot to document
504 >  this elsewhere!!!!!
505 >
506 >Release 1.32e-08Dec03 was meant to be an official 1.32e release with all
507 >the current patches and a few strategic updates from 1.33. In the end, I
508 >threw in *all* the updates from 1.33 except those that require a
509 >database upgrade or force a daemon incompatibility, or other operating
510 >incompatibility. 
511 >
512 >I haven't made 1.32-08Dec03 an official release for three reasons:
513 >- I cannot test it in production because my production system is on
514 >  release 1.33.
515 >- There is still a bit more documentation to do.
516 >- I added more of the 1.33 code than I originally planned, but some of
517 >  it such as the new 10 job history for each daemon is so neat that I
518 >  wanted to put it in your hands (one of the features not yet
519 >  documented).
520 >
521 >That said, I think this is a very good release. I have HEAVILY tested it
522 >with my regression testing, and 95% of the code has been running in my
523 >production 1.33 system since 24 November.  I encourage all of you to
524 >test it. Note, all of the daemons should be totally compatible with any
525 >other 1.32x release -- please send feedback.
526 >
527 >Once I finish the documentation and get some feedback on how it runs,
528 >I'll "officially" release it.
529 >
530 >As most of you know, from tomorrow morning, I will be out for one week
531 >and then a bit slow responding for a week or two. Thanks for all the
532 >well wishes I have received.
533 >
534 >Regards, Kern
535 >
536 >
537 >
538 >
539 >
540 >
541 >--__--__--
542 >
543 >Message: 2
544 >Subject: Re: [Bacula-users] Current Volume "Cinta-0006" not acceptable
545 >       because
546 >From: Kern Sibbald <kern@sibbald.com>
547 >To: Carlos Molina Molina <carlos_linux@hotmail.com>
548 >Cc: Phil Stracchino <alaric@caerllewys.net>,
549 >   bacula-users <bacula-users@lists.sourceforge.net>
550 >Organization: 
551 >Date: 09 Dec 2003 22:30:07 +0100
552 >
553 >
554 >--=-HANNTFvbGW9Q5KQ00dee
555 >Content-Type: text/plain; charset=ISO-8859-1
556 >Content-Transfer-Encoding: quoted-printable
557 >
558 >On Tue, 2003-12-09 at 19:03, Carlos Molina Molina wrote:
559 >  
560 >
561 >>no, I haven't the volume.... but the only thing that I need from bacula i=
562 >>    
563 >>
564 >t's=20
565 >  
566 >
567 >>that write in any volume
568 >>other thing it's that when finish it send this part of messages. I put "u=
569 >>    
570 >>
571 >se=20
572 >  
573 >
574 >>any volume"
575 >>=20
576 >>AZOG: Naboo-Backup.2003-12-09_14.12.07 Warning: Unexpected Client Job=20
577 >>message: 2801 End Backup Job TermCode=3D84 JobFiles=3D56064 ReadBytes=3D1=
578 >>    
579 >>
580 >501707569=20
581 >  
582 >
583 >>JobBytes=3D621946654
584 >>=20
585 >>AZOG: Naboo-Backup.2003-12-09_14.12.07 Fatal error: No Job status returne=
586 >>    
587 >>
588 >d=20
589 >  
590 >
591 >>from FD.
592 >>=20
593 >>What means???
594 >>    
595 >>
596 >
597 >I cannot comment on the tape Volume error messages, but the message
598 >listed above "Unexpected Client Job message ..." seems to me to come
599 >from the fact that you have upgraded that client (File daemon) to a more
600 >recent version of Bacula than you are running on your Director. Please
601 >check your version numbers. If they are both the same number they should
602 >work together. If not, you need to get them both on the same version.
603 >
604 >Be sure to read the ReleaseNotes on any upgrade to ensure you do any
605 >required database upgrading.
606 >
607 >Regards, Kern
608 >
609 >
610 >  
611 >
612 >>Thank
613 >>=20
614 >>    
615 >>
616 >>>From: Phil Stracchino <alaric@caerllewys.net>
617 >>>To: bacula-users@lists.sourceforge.net
618 >>>Subject: Re: [Bacula-users] Current Volume "Cinta-0006" not acceptable=20
619 >>>because
620 >>>Date: Tue, 9 Dec 2003 12:56:43 -0500
621 >>>
622 >>>On Tue, Dec 09, 2003 at 03:47:29PM +0000, Carlos Molina Molina wrote:
623 >>>      
624 >>>
625 >>>>How I avoid this message???, The only solution it's that I erase the=20
626 >>>>        
627 >>>>
628 >>>tape
629 >>>      
630 >>>
631 >>>>manually...
632 >>>>
633 >>>>
634 >>>>SDT-10000: Naboo-Backup.2003-12-09_12.38.04 Warning: mount.c:232=20
635 >>>>        
636 >>>>
637 >>>Director
638 >>>      
639 >>>
640 >>>>wanted Volume "Cinta-0001".
641 >>>>   Current Volume "Cinta-0006" not acceptable because:
642 >>>>   1997 Volume "Cinta-0006" not in catalog.
643 >>>>SDT-10000: Please mount Volume "Cinta-0001" on Storage Device=20
644 >>>>        
645 >>>>
646 >>>"SDT-10000"
647 >>>      
648 >>>
649 >>>>for Job Naboo-Backup.2003-12-09_12.38.04
650 >>>>Use "mount" command to release Job.
651 >>>>        
652 >>>>
653 >>>Don't you have the volume it's asking for?
654 >>>
655 >>>
656 >>>--
657 >>> .*********  Fight Back!  It may not be just YOUR life at risk. =20
658 >>>*********.
659 >>> : phil stracchino : unix ronin : renaissance man : mystic zen biker ge=
660 >>>      
661 >>>
662 >ek=20
663 >  
664 >
665 >>>:
666 >>> :  alaric@caerllewys.net : alaric-ruthven@earthlink.net : phil@latt.ne=
667 >>>      
668 >>>
669 >t =20
670 >  
671 >
672 >>>:
673 >>> :   2000 CBR929RR, 1991 VFR750F3 (foully murdered), 1986 VF500F (sold)=
674 >>>      
675 >>>
676 >  =20
677 >  
678 >
679 >>>:
680 >>> :    Linux Now!   ...Because friends don't let friends use Microsoft. =
681 >>>      
682 >>>
683 >  =20
684 >  
685 >
686 >>>:
687 >>>
688 >>>
689 >>>-------------------------------------------------------
690 >>>This SF.net email is sponsored by: SF.net Giveback Program.
691 >>>Does SourceForge.net help you be more productive?  Does it
692 >>>help you create better code?  SHARE THE LOVE, and help us help
693 >>>YOU!  Click Here: http://sourceforge.net/donate/
694 >>>_______________________________________________
695 >>>Bacula-users mailing list
696 >>>Bacula-users@lists.sourceforge.net
697 >>>https://lists.sourceforge.net/lists/listinfo/bacula-users
698 >>>      
699 >>>
700 >>=20
701 >>_________________________________________________________________
702 >>MSN Amor: busca tu =BD naranja http://latam.msn.com/amor/
703 >>=20
704 >>=20
705 >>=20
706 >>-------------------------------------------------------
707 >>This SF.net email is sponsored by: SF.net Giveback Program.
708 >>Does SourceForge.net help you be more productive?  Does it
709 >>help you create better code?  SHARE THE LOVE, and help us help
710 >>YOU!  Click Here: http://sourceforge.net/donate/
711 >>_______________________________________________
712 >>Bacula-users mailing list
713 >>Bacula-users@lists.sourceforge.net
714 >>https://lists.sourceforge.net/lists/listinfo/bacula-users
715 >>    
716 >>
717 >
718 >--=-HANNTFvbGW9Q5KQ00dee
719 >Content-Type: application/pgp-signature; name=signature.asc
720 >Content-Description: This is a digitally signed message part
721 >
722 >-----BEGIN PGP SIGNATURE-----
723 >Version: GnuPG v1.2.1 (GNU/Linux)
724 >
725 >iD8DBQA/1j7fNgfoSvWqwEgRAsEDAJ0aF6qvQVHiH0X4DCTwXQh3wux1gACfQLxl
726 >wKgzEjDQMg3v1vh4yS6kUys=
727 >=6xcc
728 >-----END PGP SIGNATURE-----
729 >
730 >--=-HANNTFvbGW9Q5KQ00dee--
731 >
732 >
733 >
734 >--__--__--
735 >
736 >Message: 3
737 >Subject: Re: [Bacula-users] Jobs awaiting execution?
738 >From: Kern Sibbald <kern@sibbald.com>
739 >To: Danie Theron <itsupport@raps.co.za>
740 >Cc: bacula-users <bacula-users@lists.sourceforge.net>
741 >Organization: 
742 >Date: 09 Dec 2003 22:39:39 +0100
743 >
744 >Hello,
745 >
746 >Move up to version 1.32d or 1.32e.  The job scheduler was totally
747 >rewritten between 1.31 and 1.32 and a number of bizarre little problems
748 >that some people (not me) were having totally went away. I suspect that
749 >they were pthreads related on non-Linux systems, but who knows ...
750 >
751 >Regards, Kern
752 >
753 >On Tue, 2003-12-09 at 12:09, Danie Theron wrote:
754 >  
755 >
756 >>Hi
757 >>
758 >>I have recently split my backups into more manageable sets , and now it
759 >>seems they are not running automatically. Here is an output when I do a
760 >>"status" command :
761 >>
762 >>Last Job BackupCatalog.2003-12-09_01.10.00 finished at 09-Dec-2003 01:10
763 >>  Files=1 Bytes=43,308,017 Termination Status=OK
764 >>Console connected at 09-Dec-2003 19:06
765 >>JobId 132 Job prometheus-rapstech.2003-12-09_19.00.03 is waiting
766 >>execution.
767 >>JobId 131 Job prometheus-consult-gis.2003-12-09_19.00.02 is waiting
768 >>execution.
769 >>JobId 130 Job prometheus-consult-documents.2003-12-09_19.00.01 is
770 >>waiting on max
771 >> Client jobs.
772 >>JobId 129 Job prometheus-system.2003-12-09_19.00.00 is running.
773 >>Level          Type     Scheduled          Name
774 >>=================================================================
775 >>Incremental    Backup   10-Dec-2003 19:00  prometheus-system
776 >>Incremental    Backup   10-Dec-2003 19:00  prometheus-consult-documents
777 >>Incremental    Backup   10-Dec-2003 19:00  prometheus-consult-gis
778 >>Incremental    Backup   10-Dec-2003 19:00  prometheus-rapstech
779 >>Full           Backup   10-Dec-2003 01:10  BackupCatalog
780 >>====
781 >>Connecting to Storage daemon File at localhost:9103
782 >>
783 >>prometheus-sd Version: 1.31a (02 Aug 2003)
784 >>Daemon started 08-Dec-2003 19:30, 3 Jobs run.
785 >>Last Job BackupCatalog.2003-12-09_01.10.00 finished at 09-Dec-2003 01:10
786 >>  Files=1 Bytes=43,308,119 Termination Status=OK
787 >>Device /data/server is mounted with Volume "backup"
788 >>    Total Bytes=791,751,921 Blocks=12,274 Bytes/block=64,506
789 >>    Positioned at File=0 Block=9,351
790 >>Device /data/server is not open.
791 >>Device /data/server is not open.
792 >>Device /data/server is not open.
793 >>Device /data/server is not open.
794 >>Full Backup job backup using Volume
795 >>"prometheus-system.2003-12-09_19.00.00" on d
796 >>evice /data/server
797 >>    Files=15,341 Bytes=602,255,638 Bytes/sec=1,517,016
798 >>    FDReadSeqNo=134,036 in_msg=96746 out_msg=5 fd=6
799 >>
800 >>
801 >>When I manually run a job it backups fine.
802 >>
803 >>Ta in advance
804 >>Daniel
805 >>
806 >>
807 >>
808 >>-------------------------------------------------------
809 >>This SF.net email is sponsored by: SF.net Giveback Program.
810 >>Does SourceForge.net help you be more productive?  Does it
811 >>help you create better code?  SHARE THE LOVE, and help us help
812 >>YOU!  Click Here: http://sourceforge.net/donate/
813 >>_______________________________________________
814 >>Bacula-users mailing list
815 >>Bacula-users@lists.sourceforge.net
816 >>https://lists.sourceforge.net/lists/listinfo/bacula-users
817 >>    
818 >>
819 >
820 >
821 >
822 >--__--__--
823 >
824 >Message: 4
825 >Date: Tue, 09 Dec 2003 14:57:32 -0800
826 >From: Gregory Brauer <greg@wildbrain.com>
827 >To: bacula-users <bacula-users@lists.sourceforge.net>
828 >Subject: Re: [Bacula-users] Mount need for every job... me too
829 >
830 >
831 >I have looked at all of the comments in this thread, but I
832 >am also having this problem and cannot seem to fix it.
833 >I am using an autochanger that blocks waiting for me to type
834 >the "mount" command every time it autoloads a tape.  It
835 >worked fine for me with 1.31, but has been doing this
836 >since I upgraded to 1.32d.  Here are some excerpts from my
837 >configuration:
838 >
839 >
840 > From bacula-dir.conf:
841 >
842 >Storage {
843 >   Autochanger = yes
844 >   Name = "kiev AIT2 Autoloader"
845 >   Address = kiev
846 >   SDPort = 9103
847 >   Password = "yV3C5gZXhF/RrYadlwKWnwAbTV1oUCXVqUIrAaUjMov+"
848 >   Device = "AIT2 Autoloader"
849 >   MediaType = "AIT2"
850 >}
851 >
852 >
853 > From bacula-sd.conf:
854 >
855 >Device {
856 >   Autochanger = yes
857 >   Changer Device = /dev/sg0
858 >   Changer Command = "/etc/bacula/mtx-changer %c %o %S %a"
859 >   Name = "AIT2 Autoloader"
860 >   Media Type = "AIT2"
861 >   Archive Device = /dev/nst0
862 >   Hardware end of medium = No;
863 >   Automatic Mount = yes;
864 >   Always Open = yes;
865 >   Removable Media = yes;
866 >}
867 >
868 >I had tried this with both Always Open = yes, and no... it worked fine
869 >with "no" under 1.31.
870 >
871 >
872 >I have also noticed that every time bacula issues a "load slot" command,
873 >I get an error message saying mtx-changer exited 1.
874 >
875 >
876 >09-Dec-2003 14:42 kiev-sd: 3303 Issuing autochanger "load slot 15" command.
877 >09-Dec-2003 14:44 kiev-sd: 3992 Bad autochanger "load slot" status=1.
878 >
879 >
880 >But if I run mtx-changer manually from the command line, it always
881 >seems to exit 0, so I'm not sure where bacula is seeing this error.
882 >
883 >
884 >basic [root@kiev bacula]$ ./mtx-changer /dev/sg0 load 15 /dev/nst0
885 >basic [root@kiev bacula]$ echo $status
886 >0
887 >
888 >
889 >I have tried increasing my sleep time on load to arbitrarily high
890 >values, but that hasn't helped.
891 >
892 >
893 >    load)
894 >#     echo "Doing mtx -f $1 load $3"
895 >       ${MTX} -f $1 load $3
896 >       rtn=$?
897 >#
898 ># Increase the sleep time if you have a slow device
899 >       #sleep 15
900 >       sleep 120
901 >       exit $rtn
902 >       ;;
903 >
904 >
905 >What else can I check?
906 >
907 >Greg
908 >
909 >
910 >
911 >--__--__--
912 >
913 >Message: 5
914 >Date: Wed, 10 Dec 2003 00:48:19 +0100
915 >From: Volker Sauer <volker@volker-sauer.de>
916 >To: Kern Sibbald <kern@sibbald.com>,
917 >   bacula-users <bacula-users@lists.sourceforge.net>
918 >Subject: [Bacula-users] Importtant: BIG Problems with schedule / bacula
919 doesn't do Differnetial
920 > backups
921 >
922 >This is an OpenPGP/MIME signed message (RFC 2440 and 3156)
923 >--------------enig1AEBD91EBCB59C2EB43FEF98
924 >Content-Type: text/plain; charset=us-ascii; format=flowed
925 >Content-Transfer-Encoding: 7bit
926 >
927 >Hallo Kern,
928 >
929 >as I already worried about in 2 other mails is now proven:
930 >
931 >Bacula doesn't do a diffential backup!
932 >
933 >My schedule is this:
934 >
935 >Schedule {
936 >         Name = "WeeklyCycle"
937 >         Run = Level=Full Pool=Full 1st tue at 2:00pm
938 >         Run = Level=Differential Pool=Full 2nd-5th tue at 7:00pm
939 >         Run = Level=Incremental Pool=Inc wed-mon at 7:00pm
940 >}
941 >
942 >
943 >and this is what list jobs says (I hope you can read that):
944 >
945 >
946 >|    55 | Zaphod                | 2003-12-02 14:00:04 | B    | F     | 
947 >504,634 | 20,669,282,940 | T         |
948 >|    56 | Arthur                | 2003-12-02 16:31:30 | B    | F     | 
949 >380,719 | 15,498,385,751 | T         |
950 >|    57 | Alexis                | 2003-12-02 18:23:45 | B    | F     | 
951 >167,710 |  5,157,651,432 | T         |
952 >|    58 | BackupCatalog         | 2003-12-02 19:23:13 | B    | F     | 
953 >       1 |    404,663,640 | T         |
954 >|    59 | ReminderIncCartridge  | 2003-12-03 08:00:05 | D    | F     | 
955 >       0 |              0 | T         |
956 >|    60 | Zaphod                | 2003-12-03 19:00:04 | B    | I     | 
957 >     693 |    262,166,208 | T         |
958 >|    61 | Arthur                | 2003-12-03 19:12:57 | B    | I     | 
959 >     314 |    889,290,521 | T         |
960 >|    62 | Alexis                | 2003-12-03 19:24:46 | B    | I     | 
961 >     748 |     56,013,471 | T         |
962 >|    63 | BackupCatalog         | 2003-12-03 22:00:04 | B    | F     | 
963 >       1 |    404,846,132 | T         |
964 >|    64 | Zaphod                | 2003-12-04 19:00:05 | B    | I     | 
965 >     740 |    385,140,941 | T         |
966 >|    65 | Arthur                | 2003-12-04 19:16:03 | B    | I     | 
967 >     441 |    904,698,439 | T         |
968 >|    66 | Alexis                | 2003-12-04 19:28:09 | B    | I     | 
969 >     669 |     68,876,161 | T         |
970 >|    67 | BackupCatalog         | 2003-12-04 22:00:04 | B    | F     | 
971 >       1 |    253,231,104 | E         |
972 >|    68 | BackupCatalog         | 0000-00-00 00:00:00 | B    | I     | 
973 >       0 |              0 | C         |
974 >|    69 | BackupCatalog         | 0000-00-00 00:00:00 | B    | I     | 
975 >       0 |              0 | C         |
976 >|    70 | BackupCatalog         | 2003-12-05 01:25:19 | B    | I     | 
977 >       1 |    405,045,253 | T         |
978 >|    71 | Zaphod                | 2003-12-05 19:00:04 | B    | I     | 
979 >   8,389 |    373,643,708 | T         |
980 >|    72 | Arthur                | 2003-12-05 19:13:59 | B    | I     | 
981 >   6,904 |  1,007,785,097 | T         |
982 >|    73 | Alexis                | 2003-12-05 19:28:23 | B    | I     | 
983 >   4,085 |    114,727,583 | T         |
984 >|    74 | BackupCatalog         | 2003-12-05 22:00:04 | B    | F     | 
985 >       1 |    407,222,289 | T         |
986 >|    75 | Zaphod                | 2003-12-06 19:00:05 | B    | I     | 
987 >     923 |    175,466,045 | T         |
988 >|    76 | Arthur                | 2003-12-06 19:14:01 | B    | I     | 
989 >   1,872 |    516,372,637 | T         |
990 >|    77 | Alexis                | 2003-12-06 19:25:01 | B    | I     | 
991 >   5,422 |    190,847,977 | T         |
992 >|    78 | BackupCatalog         | 2003-12-06 22:00:04 | B    | F     | 
993 >       1 |    408,121,544 | T         |
994 >|    79 | Zaphod                | 2003-12-07 19:00:04 | B    | I     | 
995 >   1,347 |     93,787,356 | T         |
996 >|    80 | Arthur                | 2003-12-07 19:12:06 | B    | I     | 
997 >     705 |    496,647,729 | T         |
998 >|    81 | Alexis                | 2003-12-07 19:25:08 | B    | I     | 
999 >   1,414 |    102,756,100 | T         |
1000 >|    82 | BackupCatalog         | 2003-12-07 22:00:04 | B    | F     | 
1001 >       1 |    408,519,580 | T         |
1002 >|    83 | Zaphod                | 2003-12-08 19:00:05 | B    | I     | 
1003 >   4,428 |    461,132,237 | T         |
1004 >|    84 | Arthur                | 2003-12-08 19:15:59 | B    | I     | 
1005 >     307 |    384,713,540 | T         |
1006 >|    85 | Alexis                | 2003-12-08 19:25:56 | B    | I     | 
1007 >     708 |     78,420,311 | T         |
1008 >|    86 | BackupCatalog         | 2003-12-08 22:00:04 | B    | F     | 
1009 >       1 |    409,139,688 | T         |
1010 >|    87 | ReminderFullCartridge | 2003-12-09 06:00:05 | D    | F     | 
1011 >       0 |              0 | T         |
1012 >|    88 | Zaphod                | 2003-12-09 19:00:05 | B    | F     | 
1013 >507,058 | 21,050,750,780 | T         |
1014 >|    89 | Arthur                | 2003-12-09 21:27:07 | B    | F     | 
1015 >382,397 | 15,246,847,324 | T         |
1016 >|    90 | Alexis                | 2003-12-09 23:18:30 | B    | F     | 
1017 >167,868 |  4,595,334,742 | T         |
1018 >|    91 | BackupCatalog         | 2003-12-10 00:10:05 | B    | F     | 
1019 >       1 |    528,055,685 | T         |
1020 >+-------+-----------------------+---------------------+------+-------+-----
1021 -----+----------------+-----------+
1022 >*
1023 >
1024 >Bacula did a FullBackup on December 2nd, which was the first Tuesday in 
1025 >this month. Correct. Then it did Incremenatial backups from 3rd until 
1026 >8th. Also correct.
1027 >Yesterday, on December 9th - according to my schedule there should have 
1028 >been a differential backup!! But as you can see above, bacula did a Full 
1029 >backup - without reason, I think!!
1030 >(This brings real big problems to my storage managment, because I don't 
1031 >have enough space for 4 Full-Backups a month. I urgently need diffential 
1032 >backups in the conecept)
1033 >Could the cause be, that there's a pool change! Should the diffential 
1034 >backup better go to the inc-pool??
1035 >
1036 >Please help!!
1037 >
1038 >Regards
1039 >Volker
1040 >
1041 >P.S.: this is the job output of the jobs from Tue 9th, which should have 
1042 >been differential:
1043 >
1044 >
1045 >z217-dir: Start Backup JobId 88, Job=Zaphod.2003-12-09_19.00.00
1046 >z217-sd: 3301 Issuing autochanger "loaded" command.
1047 >z217-sd: Volume "F-6" previously written, moving to end of data.
1048 >z217-sd: Ready to append to end of Volume at file=6.
1049 >z217-sd: block.c:480 End of medium on device /dev/tape. Write of 64512 
1050 >bytes got 32768.
1051 >z217-sd: End of medium on Volume "F-6" Bytes=23,935,131,136 
1052 >Blocks=371,020 at 09-Dec-2003 21:06.
1053 >z217-sd: 3301 Issuing autochanger "loaded" command.
1054 >z217-sd: 3302 Issuing autochanger "unload" command.
1055 >z217-sd: 3303 Issuing autochanger "load slot 7" command.
1056 >z217-sd: 3304 Autochanger "load slot 7" status is OK.
1057 >z217-sd: Wrote label to prelabeled Volume "F-7" on device /dev/tape
1058 >z217-sd: New volume "F-7" mounted on device /dev/tape at 09-Dec-2003 21:08.
1059 >z217-dir: Bacula 1.32d (02Nov03): 09-Dec-2003 21:27
1060 >JobId:                  88
1061 >Job:                    Zaphod.2003-12-09_19.00.00
1062 >Backup Level:           Full
1063 >Client:                 zaphod-fd
1064 >FileSet:                "Set Zaphod" 2003-11-21 16:32:26
1065 >Start time:             09-Dec-2003 19:00
1066 >End time:               09-Dec-2003 21:27
1067 >FD Files Written:       507,058
1068 >SD Files Written:       507,058
1069 >FD Bytes Written:       21,050,750,780
1070 >SD Bytes Written:       21,121,287,812
1071 >Rate:                   2387.2 KB/s
1072 >Software Compression:   None
1073 >Volume name(s):         F-6|F-7
1074 >Volume Session Id:      14
1075 >Volume Session Time:    1070650983
1076 >Last Volume Bytes:      2,327,668,804
1077 >Non-fatal FD errors:    0
1078 >SD Errors:              0
1079 >FD termination status:  OK
1080 >SD termination status:  OK
1081 >Termination:            Backup OK
1082 >
1083 >z217-dir: Begin pruning Jobs.
1084 >z217-dir: No Jobs found to prune.
1085 >z217-dir: Begin pruning Files.
1086 >z217-dir: No Files found to prune.
1087 >z217-dir: End auto prune.
1088 >
1089 >
1090 >
1091 >z217-dir: Start Backup JobId 89, Job=Arthur.2003-12-09_19.00.01
1092 >z217-dir: Bacula 1.32d (02Nov03): 09-Dec-2003 23:18
1093 >JobId:                  89
1094 >Job:                    Arthur.2003-12-09_19.00.01
1095 >Backup Level:           Full
1096 >Client:                 z217-fd
1097 >FileSet:                "Set Arthur" 2003-11-21 18:47:14
1098 >Start time:             09-Dec-2003 21:27
1099 >End time:               09-Dec-2003 23:18
1100 >FD Files Written:       382,397
1101 >SD Files Written:       382,397
1102 >FD Bytes Written:       15,246,847,324
1103 >SD Bytes Written:       15,300,937,041
1104 >Rate:                   2283.1 KB/s
1105 >Software Compression:   None
1106 >Volume name(s):         F-7
1107 >Volume Session Id:      15
1108 >Volume Session Time:    1070650983
1109 >Last Volume Bytes:      17,654,556,715
1110 >Non-fatal FD errors:    0
1111 >SD Errors:              0
1112 >FD termination status:  OK
1113 >SD termination status:  OK
1114 >Termination:            Backup OK
1115 >
1116 >z217-dir: Begin pruning Jobs.
1117 >z217-dir: No Jobs found to prune.
1118 >z217-dir: Begin pruning Files.
1119 >z217-dir: No Files found to prune.
1120 >z217-dir: End auto prune.
1121 >
1122 >
1123 >
1124 >z217-dir: Start Backup JobId 90, Job=Alexis.2003-12-09_19.00.02
1125 >z217-dir: Bacula 1.32d (02Nov03): 10-Dec-2003 00:10
1126 >JobId:                  90
1127 >Job:                    Alexis.2003-12-09_19.00.02
1128 >Backup Level:           Full
1129 >Client:                 alexis-fd
1130 >FileSet:                "Set Alexis" 2003-11-21 20:58:58
1131 >Start time:             09-Dec-2003 23:18
1132 >End time:               10-Dec-2003 00:10
1133 >FD Files Written:       167,868
1134 >SD Files Written:       167,868
1135 >FD Bytes Written:       4,595,334,742
1136 >SD Bytes Written:       4,616,435,343
1137 >Rate:                   1487.2 KB/s
1138 >Software Compression:   None
1139 >Volume name(s):         F-7
1140 >Volume Session Id:      16
1141 >Volume Session Time:    1070650983
1142 >Last Volume Bytes:      22,280,313,500
1143 >Non-fatal FD errors:    0
1144 >SD Errors:              0
1145 >FD termination status:  OK
1146 >SD termination status:  OK
1147 >Termination:            Backup OK
1148 >
1149 >z217-dir: Begin pruning Jobs.
1150 >z217-dir: No Jobs found to prune.
1151 >z217-dir: Begin pruning Files.
1152 >z217-dir: No Files found to prune.
1153 >z217-dir: End auto prune.
1154 >  
1155 >
1156 I'm trying to setup a surestore 12000e autochanger so far in my 
1157 bacula-sd.conf  i have added this
1158 Device {
1159   Name = autochanger                     #
1160   Media Type = DDS-2
1161   Archive Device = /dev/sa1
1162   AutomaticMount = yes;               # when device opened, read it
1163   AlwaysOpen = yes;
1164   LabelMedia = yes;
1165   RemovableMedia = yes;
1166   Autochanger = yes;
1167   Changer Device = /dev/pass0 #changer device
1168 }
1169 But i need to make an entry for the Changer Command =   .I have 
1170 installed mtx but there are no sample files to be found or any
1171 bacula samples for autochangers
1172 Cheers Terry
1173
1174
1175
1176
1177 -------------------------------------------------------
1178 This SF.net email is sponsored by: SF.net Giveback Program.
1179 Does SourceForge.net help you be more productive?  Does it
1180 help you create better code?  SHARE THE LOVE, and help us help
1181 YOU!  Click Here: http://sourceforge.net/donate/
1182 _______________________________________________
1183 Bacula-users mailing list
1184 Bacula-users@lists.sourceforge.net
1185 https://lists.sourceforge.net/lists/listinfo/bacula-users
1186
1187
1188 -------------------------------------------------------
1189 This SF.net email is sponsored by: SF.net Giveback Program.
1190 Does SourceForge.net help you be more productive?  Does it
1191 help you create better code?  SHARE THE LOVE, and help us help
1192 YOU!  Click Here: http://sourceforge.net/donate/
1193 _______________________________________________
1194 Bacula-users mailing list
1195 Bacula-users@lists.sourceforge.net
1196 https://lists.sourceforge.net/lists/listinfo/bacula-users