Networker

Re: [Networker] Reading/writing SAIT1 tapes on Linux that were written by solaris?

2005-11-30 18:00:44
Subject: Re: [Networker] Reading/writing SAIT1 tapes on Linux that were written by solaris?
From: Tim Mooney <mooney AT DOGBERT.CC.NDSU.NODAK DOT EDU>
To: NETWORKER AT LISTSERV.TEMPLE DOT EDU
Date: Wed, 30 Nov 2005 16:58:38 -0600
In regard to: Re: [Networker] Reading/writing SAIT1 tapes on Linux that...:

On Wed, 30 Nov 2005, Tim Mooney wrote:

TM> I'm just taking wild guesses here, but I'm wondering if you need
TM>
TM> post-install st /sbin/stinit
TM>
TM> in /etc/modules.conf, but the `mt' is triggering stinit, and that's why
TM> you don't see the problem *after* mt has been run once.

It seems to be related to the block size after all! Although it seems to
be impossible to set it on the device until a tape has been loaded in it.

Based on my tenuous understanding of stinit, I think stinit should be
setting the default block size, on a per-mode basis, for all the devices
that your stinit.def entries match.

After preparing nst3 with a tape loaded, I ran the following:

sn01:~ # mt -f /dev/nst3 setblk 0
sn01:~ # mt -f /dev/nst2 setblk 0
mt: /dev/nst2: Input/output error

nst2 doesn't have a tape in it, and is thus not accepting any mt commands
until a tape has been loaded. After this little experiment, nst3 could
mount a tape just fine from networker, but nst2 showed the same behavior
as previously mentioned.

So, is there any way to set the block size without mounting a tape first?
It seems like stinit says it has done so, but that doesn't seem to be
correct.

I think that's the problem.  I don't understand why it's happening though.

And where does it get the 512byte default setting from?

I *think* (but could be way off) that 512 bytes is the default for the
st driver.

Where can
that be set, without affecting other SCSI devices such as disk drives?

Assuming that the mode that's defined in /etc/stinit.def
applies to the device file you're using, running stinit should be
accomplishing that for you.

man 4 st on a recent version of Red Hat gives some useful information on
the defaults for the st driver, but it seems to be leaving a lot of stuff
out.  I'll probably have to install the kernel source and spending some
time looking at the driver to know more, and I may not get a chance to
do that this week.

Tim
--
Tim Mooney                              mooney AT dogbert.cc.ndsu.NoDak DOT edu
Information Technology Services         (701) 231-1076 (Voice)
Room 242-J6, IACC Building              (701) 231-8541 (Fax)
North Dakota State University, Fargo, ND 58105-5164

To sign off this list, send email to listserv AT listserv.temple DOT edu and type 
"signoff networker" in the
body of the email. Please write to networker-request AT listserv.temple DOT edu 
if you have any problems
wit this list. You can access the archives at 
http://listserv.temple.edu/archives/networker.html or
via RSS at http://listserv.temple.edu/cgi-bin/wa?RSS&L=NETWORKER