Date: Wed, 16 Jun 2010 19:14:41 -0500 From: "Dustin J. Mitchell" <dustin@zmanda.com> To: Matthew Jacob <mj@feral.com> Cc: freebsd-scsi@freebsd.org Subject: Re: sa: write returns 0 = LEOM? Message-ID: <AANLkTinO44IGhetFesm8Rm6EhY-ctLlzO72EUEyUVAHV@mail.gmail.com> In-Reply-To: <4C195EE6.1050207@feral.com> References: <AANLkTikULvhu5TRVDNAY59UvKII-BuBYBvDe83jQFLXR@mail.gmail.com> <4C195EE6.1050207@feral.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, Jun 16, 2010 at 6:31 PM, Matthew Jacob <mj@feral.com> wrote: > That is, I believe, a specific feature of Solaris (EOM detection triggers= a > zero write, but allows for trailer records). =C2=A0I seem to recall helpi= ng > architect this back in 1996. Gotcha. My plan is to introduce support for EOM detection platform-by-platform, as I can research and verify the behavior of that platform's tape driver. > Yes, I remember this code. I remember on doing test readbacks that the > residual reported was in fact incorrect- the data had actually been writt= en. > But this was really a long while back (at least 8 years ago). I don't dispute this at all. I'm often surprised when a tape drive *does* do what it claims to do! >> 1. What could cause a write syscall to return 0? >> > > I'll try and look into this. > > Do you happen to know whether the device you experienced this on was set = in > fixed block or variable block mode? I will ask. I know that Amanda always operates *as if* it was in fixed block mode (which is to say, it always reads and writes with identically-sized buffers), so the underlying driver configuration usually doesn't matter. I'll let you know what I find out. > Can't you write until you get a hard failure, back up one record (which, = of > course, you've hung onto), write a trailer label and then ask for a new > tape? Historically, Amanda has not trusted tape drives at physical EOM - or any time, really. This strategy has paid off, but as technologies have advanced it may be time to trust a bit more. Also, I was under the impression that most (or at least some) drives would not let you BSR in write mode. Thanks for looking into this! Dustin --=20 Open Source Storage Engineer http://www.zmanda.com
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?AANLkTinO44IGhetFesm8Rm6EhY-ctLlzO72EUEyUVAHV>