[linux-cifs-client][patch] prevent data integrity problems when socket starts returning EAGAINs

Shirish Pargaonkar shirishpargaonkar at gmail.com
Wed Oct 22 18:32:47 GMT 2008


This is a later version where send timeout of a socket is set using
kernel_setsockopt just once.
Have not encountered any EINTRs for any of the SMB commands.

Regards,

Shirish

On Thu, Sep 25, 2008 at 2:07 PM, Shirish Pargaonkar
<shirishpargaonkar at gmail.com> wrote:
> With the write size of 56K or even with smaller write sizes, under
> duress, writing
> over sockets can result in data corruption when socket returns EAGAIN during
> sendmsg and cifs attempts to write 14 times over 15 seconds and gives up.
>
> The data between threads can get mixed up and many times the initial message
> of one request does get sent as a later part of another request
> resulting in some
> requests not reaching the a SMB server, server thus not responding to those
> requests and cifs timing out during response and reconnecting.
>
> Change the socket from non-blocking to blocking with a timeout of 15 seconds,
> which is same as cifs trying to send a messages over non-blocking socket
> upto 15 seconds for large requests such as 56K Write Andx.
>
>
> Regards,
>
> Shirish S. Pargaonkar
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smbsend3.8.patch
Type: application/octet-stream
Size: 7879 bytes
Desc: not available
Url : http://lists.samba.org/archive/linux-cifs-client/attachments/20081022/890ac312/smbsend3.8.obj


More information about the linux-cifs-client mailing list