[Samba] libsmbclient question

Jeremy Allison jra at samba.org
Wed May 27 18:27:26 MDT 2015


On Wed, May 27, 2015 at 11:16:08PM +0200, Szilard Matyas wrote:
> Dear Gents,
> 
> We are using libsmbclient smbc_getFunctionRead to read from a Microsoft DFS
> share. Before each 64k read there are a QUERY_PATH_INFO and a
> GET_DFS_REFERRAL which slow down the transmission. Is there a way to query
> these only once at the beginning of the transmission and cache it?

Hmmm. This seems to be done inside :

SMBC_read_ctx(SMBCCTX *context,
              SMBCFILE *file,
              void *buf,
              size_t count)

where it's doing:

        status = cli_resolve_path(frame, "", context->internal->auth_info,
                                  file->srv->cli, path,
                                  &targetcli, &targetpath);

before each call to cli_read(), which does seem rather
excessive.

I'm guessing it's to allow a DFS server to go down mid-read,
and allow a replica to take over.... Let me think about this
some more.

You might want to log this as a bug to make it easier to
track.

Thanks,

	Jeremy.


More information about the samba mailing list