Environment
Novell Open Enterprise Server 2 SP3 (OES2SP3)
Domain Services for Windows
DSfW
Samba 3.0.36
Situation
Read failure for 4. Error = connection reset by peer is seen in the /var/log/messages
Resolution
The message "Read failure for 4. Error = connection reset by peer." is specific to samba 3.0.36, oes2sp3.
The following link explain the root cause:
Upgrading to OES11SP1 will resolve this error message. The samba version in OES11SP1 is 3.6.3 and this version of samba resolves the error message.
Until the upgrade can be performed disabling oplocks will help with the error.
In the /etc/samba/smb.conf add the following to the global sectionoplocks = no
kernel oplocks = no
Cause
From http://www.samba.org/~tpot/articles/connection-reset-by-peer
"SMB/CIFS operates on two TCP ports, port 139 and port 445. In the interests of minimizing waiting time, Windows opens two connections simultaneously. One to port 139 and another to port 445. When it receives a response to one of these connection requests, the other one is discarded. When Samba tries to read a packet from the discarded connection, it receives the connection reset by peer error, and this is dutifully logged."
"SMB/CIFS operates on two TCP ports, port 139 and port 445. In the interests of minimizing waiting time, Windows opens two connections simultaneously. One to port 139 and another to port 445. When it receives a response to one of these connection requests, the other one is discarded. When Samba tries to read a packet from the discarded connection, it receives the connection reset by peer error, and this is dutifully logged."
Additional Information
oplocks:
It allows the clients to aggressively cache files locally and you may want to disable this option for unreliable network environments (it is turned on by default in Windows NT Servers).
Default: oplocks = yes
kernel oplocks (G):
Default: kernel oplocks = yes
level2 oplocks
Note the oplocks parameter must be set to yes on this
share in order for this parameter to have any effect.
Default: level2 oplocks = yes
client ntlmv2 auth
Default: client ntlmv2 auth = yes