On Oct 17, 2008, at 12:33 PM, Erik P. Olsen wrote:
> On 17/10/08 12:33, Martijn de Munnik wrote:
>> I really don't know how to solve this problem? Why is bacula unable
>> to
>> move to the end of data?
>
> It has sometimes happened to me also. Maybe it's because the tape is
> positioned
> different from where Bacula believes it is. Try to change the error
> flag to
> append and see if it will be accepted by Bacula. I have several
> times been able
> to cure the problem this way.
I believe this was a known bug in earlier versions of Bacula.
>
>
>>
>>
>> On Oct 15, 2008, at 12:22 AM, Bacula wrote:
>>
>>> 15-Oct 00:05 chet-dir JobId 754: Start Backup JobId 754,
>>> Job=Home_Directories_Job_Chet.2008-10-15_00.05.06
>>> 15-Oct 00:05 chet-sd JobId 754: 3307 Issuing autochanger "unload
>>> slot 3, drive 0" command.
>>> 15-Oct 00:08 chet-dir JobId 754: Using Device "ExabyteVXA-2Drive"
>>> 15-Oct 00:08 chet-sd JobId 754: 3301 Issuing autochanger "loaded?
>>> drive 0" command.
>>> 15-Oct 00:08 chet-sd JobId 754: 3302 Autochanger "loaded? drive 0",
>>> result: nothing loaded.
>>> 15-Oct 00:08 chet-sd JobId 754: 3304 Issuing autochanger "load slot
>>> 1, drive 0" command.
>>> 15-Oct 00:08 chet-sd JobId 754: 3305 Autochanger "load slot 1, drive
>>> 0", status is OK.
>>> 15-Oct 00:08 chet-sd JobId 754: 3301 Issuing autochanger "loaded?
>>> drive 0" command.
>>> 15-Oct 00:08 chet-sd JobId 754: 3302 Autochanger "loaded? drive 0",
>>> result is Slot 1.
>>> 15-Oct 00:08 chet-sd JobId 754: Volume "A0000001" previously
>>> written, moving to end of data.
>>> 15-Oct 00:15 chet-sd JobId 754: Error: Unable to position to end of
>>> data on device "Exabyte VXA-2 Drive" (/dev/rmt/0cbn): ERR=dev.c:1326
>>> read error on "Exabyte VXA-2 Drive" (/dev/rmt/0cbn). ERR=I/O error.
>>>
>>> 15-Oct 00:15 chet-sd JobId 754: Marking Volume "A0000001" in Error
>>> in Catalog.
>>> 15-Oct 00:15 chet-dir JobId 754: Recycled volume "A0000004"
>>> 15-Oct 00:15 chet-sd JobId 754: 3307 Issuing autochanger "unload
>>> slot 1, drive 0" command.
>>> 15-Oct 00:16 chet-sd JobId 754: 3304 Issuing autochanger "load slot
>>> 4, drive 0" command.
>>> 15-Oct 00:17 chet-sd JobId 754: 3305 Autochanger "load slot 4, drive
>>> 0", status is OK.
>>> 15-Oct 00:17 chet-sd JobId 754: 3301 Issuing autochanger "loaded?
>>> drive 0" command.
>>> 15-Oct 00:17 chet-sd JobId 754: 3302 Autochanger "loaded? drive 0",
>>> result is Slot 4.
>>> 15-Oct 00:17 chet-sd JobId 754: Recycled volume "A0000004" on device
>>> "Exabyte VXA-2 Drive" (/dev/rmt/0cbn), all previous data lost.
>>> 15-Oct 00:22 chet-sd JobId 754: Job write elapsed time = 00:04:37,
>>> Transfer rate = 4.819 M bytes/second
>>
>> My device config in bacula-sd.conf, system is Solaris 10 on x86 (Sun
>> V20Z) with an Exabyte VXA2 library.
>>
>> Autochanger {
>> Name = "Exabyte VXA-2 PacketLoader 1x10"
>> Device = "Exabyte VXA-2 Drive"
>> Changer Device = /dev/scsi/changer/c2t0d0
>> Changer Command = "/opt/csw/etc/bacula/mtx-changer %c %o %S %a %d"
>> }
>>
>> Device {
>> Name = "Exabyte VXA-2 Drive"
>> Drive Index = 0
>> Media Type = "VXA-2"
>> Device Type = Tape
>> Archive Device = /dev/rmt/0cbn
>> AutomaticMount = yes
>> AlwaysOpen = yes
>> RemovableMedia = yes
>> RandomAccess = no
>> AutoChanger = yes
>> Changer Command = "/opt/csw/etc/bacula/mtx-changer %c %o %S %a %d"
>> Alert Command = "sh -c '/opt/csw/sbin/tapeinfo -f %c |grep
>> TapeAlert|cat'"
>> Changer Device = /dev/scsi/changer/c2t0d0
>> Label Media = yes
>> Offline On Unmount = no
>> Hardware End of Medium = no
>> BSF at EOM = yes
>> Backward Space Record = no
>> Fast Forward Space File = no
>> Two EOF = yes
>> }
>>
>> Output of test:
>>
>> [munnik@chet]{/opt/csw/bin}>sudo /opt/csw/sbin/btape -c /opt/csw/etc/
>> bacula/bacula-sd.conf /dev/rmt/0cbn
>> Tape block granularity is 1024 bytes.
>> btape: butil.c:285 Using device: "/dev/rmt/0cbn" for writing.
>> 17-Oct 12:22 btape JobId 0: 3301 Issuing autochanger "loaded? drive
>> 0"
>> command.
>> 17-Oct 12:22 btape JobId 0: 3302 Autochanger "loaded? drive 0",
>> result
>> is Slot 4.
>> 17-Oct 12:23 btape JobId 0: 3301 Issuing autochanger "loaded? drive
>> 0"
>> command.
>> 17-Oct 12:23 btape JobId 0: 3302 Autochanger "loaded? drive 0",
>> result
>> is Slot 4.
>> btape: btape.c:372 open device "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn): OK
>> *test
>>
>> === Write, rewind, and re-read test ===
>>
>> I'm going to write 1000 records and an EOF
>> then write 1000 records and an EOF, then rewind,
>> and re-read the data to verify that it is correct.
>>
>> This is an *essential* feature ...
>>
>> btape: btape.c:831 Wrote 1000 blocks of 64412 bytes.
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:847 Wrote 1000 blocks of 64412 bytes.
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:856 Rewind OK.
>> 1000 blocks re-read correctly.
>> Got EOF on tape.
>> 1000 blocks re-read correctly.
>> === Test Succeeded. End Write, rewind, and re-read test ===
>>
>>
>> === Write, rewind, and position test ===
>>
>> I'm going to write 1000 records and an EOF
>> then write 1000 records and an EOF, then rewind,
>> and position to a few blocks and verify that it is correct.
>>
>> This is an *essential* feature ...
>>
>> btape: btape.c:943 Wrote 1000 blocks of 64412 bytes.
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:959 Wrote 1000 blocks of 64412 bytes.
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:968 Rewind OK.
>> Reposition to file:block 0:4
>> Block 5 re-read correctly.
>> Reposition to file:block 0:200
>> Block 201 re-read correctly.
>> Reposition to file:block 0:999
>> Block 1000 re-read correctly.
>> Reposition to file:block 1:0
>> Block 1001 re-read correctly.
>> Reposition to file:block 1:600
>> Block 1601 re-read correctly.
>> Reposition to file:block 1:999
>> Block 2000 re-read correctly.
>> === Test Succeeded. End Write, rewind, and re-read test ===
>>
>>
>>
>> === Append files test ===
>>
>> This test is essential to Bacula.
>>
>> I'm going to write one record in file 0,
>> two records in file 1,
>> and three records in file 2
>>
>> btape: btape.c:475 Rewound "Exabyte VXA-2 Drive" (/dev/rmt/0cbn)
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> 17-Oct 12:25 btape JobId 0: 3301 Issuing autochanger "loaded? drive
>> 0"
>> command.
>> 17-Oct 12:25 btape JobId 0: 3302 Autochanger "loaded? drive 0",
>> result
>> is Slot 4.
>> btape: btape.c:372 open device "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn): OK
>> btape: btape.c:475 Rewound "Exabyte VXA-2 Drive" (/dev/rmt/0cbn)
>> btape: btape.c:1097 Now moving to end of medium.
>> btape: btape.c:526 Moved to end of medium.
>> We should be in file 3. I am at file 3. This is correct!
>>
>> Now the important part, I am going to attempt to append to the tape.
>>
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:475 Rewound "Exabyte VXA-2 Drive" (/dev/rmt/0cbn)
>> Done appending, there should be no I/O errors
>>
>> Doing Bacula scan of blocks:
>> 1 block of 64448 bytes in file 1
>> End of File mark.
>> 2 blocks of 64448 bytes in file 2
>> End of File mark.
>> 3 blocks of 64448 bytes in file 3
>> End of File mark.
>> 1 block of 64448 bytes in file 4
>> End of File mark.
>> Total files=4, blocks=7, bytes = 451,136
>> End scanning the tape.
>> We should be in file 4. I am at file 4. This is correct!
>>
>> The above Bacula scan should have output identical to what follows.
>> Please double check it ...
>> === Sample correct output ===
>> 1 block of 64448 bytes in file 1
>> End of File mark.
>> 2 blocks of 64448 bytes in file 2
>> End of File mark.
>> 3 blocks of 64448 bytes in file 3
>> End of File mark.
>> 1 block of 64448 bytes in file 4
>> End of File mark.
>> Total files=4, blocks=7, bytes = 451,136
>> === End sample correct output ===
>>
>> If the above scan output is not identical to the
>> sample output, you MUST correct the problem
>> or Bacula will not be able to write multiple Jobs to
>> the tape.
>>
>> Skipping read backwards test because BSR turned off.
>>
>>
>> === Forward space files test ===
>>
>> This test is essential to Bacula.
>>
>> I'm going to write five files then test forward spacing
>>
>> btape: btape.c:475 Rewound "Exabyte VXA-2 Drive" (/dev/rmt/0cbn)
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:1577 Wrote one record of 64412 bytes.
>> btape: btape.c:1579 Wrote block to device.
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:505 Wrote 1 EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>> btape: btape.c:475 Rewound "Exabyte VXA-2 Drive" (/dev/rmt/0cbn)
>> btape: btape.c:1311 Now forward spacing 1 file.
>> We should be in file 1. I am at file 1. This is correct!
>> btape: btape.c:1323 Now forward spacing 2 files.
>> We should be in file 3. I am at file 3. This is correct!
>> btape: btape.c:475 Rewound "Exabyte VXA-2 Drive" (/dev/rmt/0cbn)
>> btape: btape.c:1336 Now forward spacing 4 files.
>> We should be in file 4. I am at file 4. This is correct!
>>
>> btape: btape.c:1354 Now forward spacing 1 more file.
>> We should be in file 5. I am at file 5. This is correct!
>>
>> === End Forward space files test ===
>>
>>
>> Ah, I see you have an autochanger configured.
>> To test the autochanger you must have a blank tape
>> that I can write on in Slot 1.
>>
>> Do you wish to continue with the Autochanger test? (y/n): y
>>
>>
>> === Autochanger test ===
>>
>> 3301 Issuing autochanger "loaded" command.
>> Slot 4 loaded. I am going to unload it.
>> 3302 Issuing autochanger "unload 4 0" command.
>> unload status=OK 0
>> 3303 Issuing autochanger "load 1 0" command.
>> 3303 Autochanger "load 1 0" status is OK.
>> 17-Oct 12:30 btape JobId 0: 3301 Issuing autochanger "loaded? drive
>> 0"
>> command.
>> 17-Oct 12:30 btape JobId 0: 3302 Autochanger "loaded? drive 0",
>> result
>> is Slot 1.
>> btape: btape.c:372 open device "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn): OK
>> btape: btape.c:1241 Rewound "Exabyte VXA-2 Drive" (/dev/rmt/0cbn)
>> btape: btape.c:1248 Wrote EOF to "Exabyte VXA-2 Drive" (/dev/rmt/
>> 0cbn)
>>
>> The test autochanger worked!!
>
> --
> Erik.
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's
> challenge
> Build the coolest Linux based applications with Moblin SDK & win
> great prizes
> Grand prize is a trip for two to an Open Source event anywhere in
> the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> Bacula-users mailing list
> Bacula-users AT lists.sourceforge DOT net
> https://lists.sourceforge.net/lists/listinfo/bacula-users
--
Dan Langille
http://langille.org/
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users
|