Gavin: On Mon, Feb 23, 2004 at 04:01:51PM +0100, Dr Gavin Seddon wrote: > I have tried mt setblk 0 > but now the error is: > > tar: /dev/st0: Wrote only 0 of 10240 bytes> tar: Error is not > recoverable: exiting now> > > Can anyone help? > Gavin.
Your problem is curious as I too have no difficulty (although I seldom use "tar", preferring "dump" and "restore") with my SCSI drive. Please provide the tape drive description, and the output of "mt -f /dev/st0 status" (with a tape in the drive). As well, I presume that /dev/tape is linked to /dev/st0 (you may prefer /dev/nst0 to avoid rewinds). Finally, with a blank or re-usable tape in the drive, can you "dd" some records to it, write setmarks, and then repeat successfully, as per: echo "Some text to go to the tape" | dd of=/dev/nst0 count=1 mt -f /dev/nst0 wset 1 echo "Another line of text for the tape" | dd of=/dev/nst0 count=1 mt -f /dev/nst0 wset 1 mt -f /dev/nst0 rewi dd if=/dev/nst0 count=1 mt -f /dev/nst0 fss 1 dd if=/dev/nst0 count=1 Assuming I coded this correctly, you should write 2 text records followed by a setmark each, rewind the tape, and then read them back (sending the output to the console). At least this would confirm your SCSI drive is functioning. By the way, "tar" uses a block size of 10240 bytes. A previous correspondent suggested setblk of zero (which I happen to use too), but the reported write block was 4096 bytes (of the 10240 that "tar" expected to write. That value is suspiciously like the block size for pipes and other file system devices - implying "/dev/tape" may not point to where you think. Did you happen to try a setblk of 10240? Dean > -- > Dr Gavin Seddon <[EMAIL PROTECTED]> > University of Manchester > > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] > -- Dean Provins 50.950333,-114.037916 [EMAIL PROTECTED] KeyID at at pgpkeys.mit.edu:11371: 0x9643AE65 -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]