Date: Sat, 25 Apr 1998 21:33:00 -0400 From: Harlan Stenn <Harlan.Stenn@pfcs.com> To: freebsd-scsi@FreeBSD.ORG Subject: Re: does CAM do this? Message-ID: <15923.893554380@brown.pfcs.com> In-Reply-To: "Louis A. Mamakos"'s (louie@TransSys.COM) message dated Sat, 25 Apr 1998 21:14:32. <199804260114.VAA01065@whizzo.TransSys.COM>
next in thread | previous in thread | raw e-mail | index | archive | help
> > > > What is the blocksize of the current tape record? > > > > > > Unless you're tape drive is clairvoyant, you can't know that > > > until you read the record (or attempt to). > > > > The problem is that a read() to the (default) tape drive under FreeBSD > > returns exactly the number of bytes you asked for, so there is no way to > > determine the actual number of bytes on the tape record. > > No, it returns no more than you asked for. That why you should do a > read() of a record larger than you expect or can support, and it will > return the number written in the tape record. I beg to differ. I agree that the read will return no more than I ask for. However... With the default tape drive configuration (on the drives I've tested), if I have a Large file on the tape blocked at, say, 10k bytes, if I issue a read of "more than 10k but less than the size of the file" I'll get back exactly what I asked for. I cannot tell that the tape was blocked at 10k bytes. H To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-scsi" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?15923.893554380>