[Samba] SMB2 leases slowing down shared access to files
jra at samba.org
Fri Dec 7 19:01:24 UTC 2018
On Fri, Dec 07, 2018 at 06:40:53AM +0100, Fabian Fritz via samba wrote:
> we recently updated to Samba 4.9.2 (running on a Solaris 10 server).
> All our client machines are Windows 7 PCs. Since then however, we
> noticed that if one client opens an executable from a share and
> somebody else tries to copy that folder to their local PC, it takes an
> incredibly long time; Sometimes it doesn't work at all.
> Also, if somebody has an .xlsx-File open, other people have to wait
> for a long time as well or cannot open that file at all. Before the
> update, users just got a notification that somebody else had opened
> the spreadsheet and they could just choose to open it read-only and
> that worked fine.
> Investigating this, I first tried putting ".exe" in the "veto oplock
> files" list. After I also put dlls and everything the program accessed
> in there as well, I could copy the folder from a share much faster, as
> before. As this doesn't take care of the problems with Office
> documents, I tried setting "smb2 leases = no" instead. Immediately
> everything started working fast again. It also brought back the dialog
> window in Office, asking you if you want to have read-only access. It
> seems like files that have "LEASE(LWH)" as the lock type in smbstatus
> have this problem.
> I was surprised that smb2 leases seem to slow everything down, as the
> documentation suggests that you can expect a speedup from this. There
> were no obvious errors in the log file.
Leases are a big win for non-shared access (which is 90% of all
file access). Shared access does slow down on first open as the
server has to revoke the existing leases before clients can
More information about the samba