SCSI Tape Drive reading "other" UNIX

SCSI Tape Drive reading "other" UNIX

Post by Farra » Tue, 29 Dec 1998 04:00:00



I have a 4mm DAT SCSI tape drive that works fine when reading and writing
natively under Linux.  My problem is that I have a tar tape that was created
on a SUN/Sparc.

I was able to use dd to pull some data off (looked at data and found source
file fragments imbedded.)  It does look like a tar file (somewhat), the
header looks bogus and Linux complains that its not in tar format.

I am hoping that the problem I am having can be rectified by changing the
blocking factor (or something easy like that.)  Any help would be greatly
appreciated.

 
 
 

SCSI Tape Drive reading "other" UNIX

Post by Khalid M. Baheyeldi » Wed, 30 Dec 1998 04:00:00


I am not sure if this will solve your problem or not,
but I have used the same technique for proting data from
Motorola 680x0 based UNIX systems and MIPS RISC based
systems to Intel UNIX systems, so it may work for you:

Insert the tape and use the following command:

dd if=/dev/your-tape conv=swab | tar tvf -

If you see a list of files, then do it again
using "tar xvf".

Regards


> I have a 4mm DAT SCSI tape drive that works fine when reading and writing
> natively under Linux.  My problem is that I have a tar tape that was created
> on a SUN/Sparc.

> I was able to use dd to pull some data off (looked at data and found source
> file fragments imbedded.)  It does look like a tar file (somewhat), the
> header looks bogus and Linux complains that its not in tar format.

> I am hoping that the problem I am having can be rectified by changing the
> blocking factor (or something easy like that.)  Any help would be greatly
> appreciated.

--
Khalid M. Baheyeldin
Senior IT Consultant
Remove all the X characters in my e-mail address to reply

 
 
 

SCSI Tape Drive reading "other" UNIX

Post by Michael Meissne » Wed, 30 Dec 1998 04:00:00



> I have a 4mm DAT SCSI tape drive that works fine when reading and writing
> natively under Linux.  My problem is that I have a tar tape that was created
> on a SUN/Sparc.

> I was able to use dd to pull some data off (looked at data and found source
> file fragments imbedded.)  It does look like a tar file (somewhat), the
> header looks bogus and Linux complains that its not in tar format.

I suspect your problem is the Sparc wrote the tape using a different blocksize
than Linux is reading.  By default under Linux, scsi tapes are assumed to have
a block size of 512 bytes, which means the kernel will read 512 bytes per
block, irregarless of what you tell tar is the blocksize.

You should use the mt command to change the block size (if you change the block
size to 0, then the kernel will handle variable sized tape blocks).  Thus, if
your tape device is /dev/nst0, you should do:

        mt -f /dev/nst0 setblk 0

Note, if you have mt 0.5 (ie, RedHat 5.2), there is a bug in it when you use -f
along with an option taking a numeric argument, and you should upgrade to mt
0.5b or later or do:

        env TAPE=/dev/nst0 mt setblk 0

A second problem is the use of hardware compression.  You might need to enable
or disable h/w compression on the linux or sparc side.  Many of the 2 gig DDS-1
DAT tape drives don't have hardware compression, so if you have such a tape
drive on the Linux box and a tape drive on the Sun that automagically turns on
compression, you will need to disable it on the Sun when making the tape.  On
the Linux side to enable compression (assuming your tape drive supports it),
do:

        mt -f /dev/nst0 compression 1

and do the following to disable it:

        mt -f /dev/nst0 compression 0

--
Michael Meissner, Cygnus Solutions (Massachusetts office)
4th floor, 955 Massachusetts Avenue, Cambridge, MA 02139, USA

 
 
 

1. SCSI Tape drive "I/O error when reading"

I have an Exabyte SCSI Tape drive and the Kernel
does recongnize it as being on /dev/st0 upon bootup.
I can write to it with tar:
tar -cf /dev/st0 /*
but when I try to read from it:
tar -xf /dev/st0
I just get "tar: read error on /dev/st0: I/O Error"

Any ideas what I should be doing that I'm not?

-Shoel Perelman

2. wine problem

3. GETSERVBYNAME()????????????????????"""""""""""""

4. Configure EMACS for Python

5. Need help making tape drive "Available" after "Defining"

6. Training for Retards? (somewhat off-topic)

7. SCSI Tape "Unable to get major 9 for SCSI Tapes"

8. kernel 2.6 & ibm hostraid (adaptec)

9. """"""""My SoundBlast 16 pnp isn't up yet""""""""""""

10. "Novell-like","non-TCP/IP","networking" OS to place Unix

11. SCSI Tape Drive Not Recognized - "Termination" Problem?

12. SCSI Tape Drive prob: mt says "No such device"

13. scsi tape drive and "dump"