[linux-cifs-client] use non-zero vcnumbers patch

Christopher R. Hertel crh at ubiqx.mn.org
Wed Feb 4 02:43:17 GMT 2009


Jeff Layton wrote:
:
:
> So what happens at reconnect? Shouldn't we "reset" all the vcnums?
> Shouldn't the first session setup on the reconnected socket use vcnum
> 0? I seem to recall reading that vcnum of 0 has some significance for
> the server...

The server sees VC number 0 from a given client to be the base VC.  Older
servers would drop all connections with a client if a new VC=0 from that
client was established.  TCP wasn't the only transport back then, so there
were situations in which the server might not notice that the client had reset.

I ran into a problem when I was testing jCIFS several years ago.  jCIFS
would send VC=0 whenever it connected, and all other CIFS connections (eg.,
smbclient and--back then--smbfs) from the same Linux box would drop.  jCIFS
now sends a minumum VC number of 1.

Microsoft ran into this when customers started putting clients behind NATs.
 The Windows server would assume (based on the IP address of the client)
that all of the connections were from the same client.  Each new client that
connected (Windows clients send VC=0) would cause any other connected client
to be dropped.  Only one client at a time could connect through the NAT and
the attempts at reconnecting would cause a complete failure.

Microsoft fixed this on the server side.  There's a KB article on it somewhere.

My general recommendation is that clients never send VC=0.

:)

Chris -)-----

-- 
"Implementing CIFS - the Common Internet FileSystem" ISBN: 013047116X
Samba Team -- http://www.samba.org/     -)-----   Christopher R. Hertel
jCIFS Team -- http://jcifs.samba.org/   -)-----   ubiqx development, uninq.
ubiqx Team -- http://www.ubiqx.org/     -)-----   crh at ubiqx.mn.org
OnLineBook -- http://ubiqx.org/cifs/    -)-----   crh at ubiqx.org


More information about the linux-cifs-client mailing list