[PATCH] DFS connection cache fix

Grégoire Menuel gregoire.menuel at gmail.com
Tue Jan 29 08:22:05 MST 2013


Hi !

I've encountered an annoying bug using GVFS with a DFS server which
uses DFS proxy shares. The time used to list the files in a
subdirectory is really long. I've traced it back to a bug in
libsmbclient. It seems that the connection chaching is not done
correctly when browsing such shares and thus the client opens a new
connection (actually two, one to the first DFS server, and a second
after resolving the real path of the DFS share) each time it needs to
do a request for a file. So when listing a directory containing 50
files the gvfs daemon will open something like 100 concurrent
connections.

I've opened a bug for this problem with a bit more detailed
explanation (9556 : https://bugzilla.samba.org/show_bug.cgi?id=9556 )

I've done a small patch (attached) which solve the problem (at least
it seems to), but it seems a bit hackish for me. Can anyone tell me if
the patch is any good, or if there is a better way to solve this
problem ?

Regards,
--
Grégoire Menuel
xmpp:omega at im.apinc.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fix-cache-dfs.diff
Type: application/octet-stream
Size: 452 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20130129/0cbd372e/attachment.obj>


More information about the samba-technical mailing list