Data Corruption bug with Samba's vfs_iouring and Linux 5.6.7/5.7rc3

Jeremy Allison jra at samba.org
Fri May 8 05:32:31 UTC 2020


On Fri, May 08, 2020 at 10:39:38AM +0530, Anoop C S wrote:
> On Thu, 2020-05-07 at 21:07 -0700, Jeremy Allison via samba-technical
> wrote:
> > On Thu, May 07, 2020 at 02:30:02PM -0700, Jeremy Allison wrote:
> > > On Wed, May 06, 2020 at 03:53:26PM +0530, Anoop C S via samba-
> > > technical wrote:
> > > > > reproduce the issue.
> > > > 
> > > > I could reproduce the difference in SHA256 checksum after copying
> > > > a
> > > > directory with 100 copies of test file(provided by reporter) from
> > > > io_uring VFS module enabled share using Windows explorer(right-
> > > > click-
> > > > > copy/paste). Only 5 out of 100 files had correct checksum after
> > > > > copy
> > > > operation :-/
> > > 
> > > Anoop,
> > > 
> > > I'm working on a fix for the vfs_io_uring module
> > > to retry short reads/writes.
> > > 
> > > Do you still have your test environment so
> > > you can test what I come up with ? I don't
> > > have a reproducer here at home so I'll be
> > > dependent on you to see if the fix works.
> > 
> > Anoop, here is a *MASSIVELY* prototype fix
> > for the io_uring short read problem. It still
> > is very ugly and contain extra debugs etc.
> > 
> > It works for me here if I enable the JRATEST
> > code that forces short reads if read_len > 4096,
> > but I never was able to reproduce the Windows
> > issue (my kernel isn't modern enough).
> > 
> > Can you test it on your Windows environment
> > and see if it fixes the SHA256 checksum problem
> > after copying 100 test files ?
> 
> Your patch fixes mismatch in SHA256 checksum of 100 bin files copied
> using Windows explorer in my environment.

WooHoo! Production-ready, here I come :-).

Thanks so much for testing Anoop !



More information about the samba-technical mailing list