Bug 243069 - usb tape error
Summary: usb tape error
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: usb (show other bugs)
Version: 11.3-STABLE
Hardware: amd64 Any
: --- Affects Only Me
Assignee: freebsd-usb mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-01-03 22:04 UTC by wayne anschutz
Modified: 2020-01-06 20:20 UTC (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description wayne anschutz 2020-01-03 22:04:55 UTC
Every write to a usb dat160 tape drive results in a CAM error and a series of scsi errors.  Tape will successfully read tar and dd formats.  It tries to read cpio but is not successful (no error generated).

Questions: Will stable version 12.1 fix?  Will change to dat160 scsi lvd fix?

Wayne
Comment 1 Alexander Motin freebsd_committer 2020-01-03 22:22:08 UTC
Wayne, my crystal ball is still not functional after past holidays, I can't see the errors on your monitor clearly enough.  Could you provide more information?
Comment 2 wayne anschutz 2020-01-04 21:23:17 UTC
Here is the error list for this problem.

(sa0:umass-sim0:0:0:0): WRITE FILEMARKS(6). CDB: 10 00 00 00 02 00
(sa0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(sa0:umass-sim0:0:0:0): Error 5, Retries exhausted
(sa0:umass-sim0:0:0:0): READ POSITION. CDB: 34 06 00 00 00 00 00 00 00 00
(sa0:umass-sim0:0:0:0): CAM status: SCSI Status Error
(sa0:umass-sim0:0:0:0): SCSI status: Check Condition
(sa0:umass-sim0:0:0:0): SCSI sense: UNIT ATTENTION asc:29,2 (SCSI bus reset occu
rred)
(sa0:umass-sim0:0:0:0): Retrying command (per sense data)
(sa0:umass-sim0:0:0:0): failed to write terminating filemark(s)
(sa0:umass-sim0:0:0:0): REWIND. CDB: 01 00 00 00 00 00
(sa0:umass-sim0:0:0:0): CAM status: CCB request completed with an error
(sa0:umass-sim0:0:0:0): Retrying command
(sa0:umass-sim0:0:0:0): REWIND. CDB: 01 00 00 00 00 00
(sa0:umass-sim0:0:0:0): CAM status: SCSI Status Error
(sa0:umass-sim0:0:0:0): SCSI status: Check Condition
(sa0:umass-sim0:0:0:0): SCSI sense: UNIT ATTENTION asc:29,2 (SCSI bus reset occu
rred)
(sa0:umass-sim0:0:0:0): Retrying command (per sense data)

Wayne
Comment 3 wayne anschutz 2020-01-04 21:38:55 UTC
Note that I took an HP dat 160 out of a SCO box and  tested in the BSD box.  Same errors were generated!

Wayne
Comment 4 wayne anschutz 2020-01-05 17:47:51 UTC
Folks this has been solved!  Someone responded and suggested a blocksize issue.  We always set the blocksize to 0 and let the drive auto handle blocksize.  We have been assuming that out-of-the-box tape drives default to blocksize 0.  Either BSD messed with it or it was not defaulted to 0. Issuing the command mt blocksize 0 solved the write problem.

Many thanks for everyones assistance with this!  I would have ordered the parts for a scsi tape on Monday.

Wayne
Comment 5 wayne anschutz 2020-01-06 20:20:31 UTC
Sorry, but I made an error on my last post.  Setting blocksize did not cure the problem, but using dd only give a scsi rewind error.  The data written to tape reads correctly and it will be useable as a backup.  Please continue work on this error for others.

Wayne