ray@vantage.UUCP (Ray Liere) (03/08/89)
We have an HP9000/540 with an HP7970E tape drive, running HP-UX 5.21. I am having trouble getting the system to know when it has reached the iphysical end of the tape -- i.e, the foil strip. This all started by my wanting to mount a tape, go all the way to the end, and then rewind it. I had heard that this was a good idea on new tapes, and also for ones that have had information archived on them for a while -- to relieve any interlayer tape stress and to also juggle/jiggle/jumble the tape layers and thereby reduce print through. So, I figured ... easy! I wrote a script that issues "mt fsf" repeatedly, figuring that when it gets to the foil, mt will generate an error, I will detect the error and rewind the tape. Here are our /dev/rmt entires -- crw------- 1 root other 11 0x040004 Jul 15 1985 0mn crw------- 1 root other 11 0x040006 Mar 27 1985 0mn.bcm (the second one is Berkeley Compatibility Mode -- whatever that is ... needed per the mt command's documentation) I tried both /dev's, with the same result: the tape goes past the foil and off of its reel! I read in the System Admin manual about a compatibility bit dealing with tape driver changes made between 4.2 and 5.x, to allow some of the newer tape drives to stream. Also there is mention of this change in the update documentation that comes (in a file) with HP-UX updates. There is a difference of opinion in which bit you flip (0x000008 or 0x000080), depending on where you read ... so I tried both and still no luck. It would seem to me that detecting EOT would be super important when you are writing or reading a tape. We use mainly cartridge tapes, so perhaps I have been lucky so far and never written/read a full reel of tape -- surely the system allows one to (easily) detect EOT ... or do I have to be writing/ reading (rather than skipping?). Thanks for any enlightenment that you can provide. Ray Liere Vantage Consulting and Research Corporation voice: (503)657-7294 uucp: hplabs!hpfcla!hpubvwa!vantage!ray