Recommended leasing mode on SMB for use with ArcGIS?

9304
2
Jump to solution
03-08-2020 10:26 PM
by Anonymous User
Not applicable

As I understand, the accepted conventional wisdom on working with file shares and ArcGIS Server is that opportunistic locking should be disabled to workaround potential issues that can arise. This is highlighted in the ArcGIS Server Common Problems and Solutions guide.

Historically, the only way to disable opportunistic locks on a Windows machine was to disable the use of SMB2/3 to force the use of now-deprecated SMB1 protocol where opportunistic locking could be disabled via the registry. However these days SMB2/3 share can be configured using PowerShell via Set-SmbShare with the -LeasingMode parameter which gives us some additional options to continue working with current versions of SMB2/3, documented by Microsoft as: 

-LeasingMode


Allow admins to stop leases and oplocks.

  • Full = default SMB3
  • Shared = grant read-caching lease but not write or handle-caching
  • None = no oplocks or leases, like modified SMB1/3

Notably, setting -LeasingMode to None provides a mechanism to disable opportunistic locking without having to revert back to a deprecated version of the SMB protocol. However this also introduces an additional level of granularity with the shared leasing mode, where read caching is enabled but write and handle caching is disabled.

Given that any number of clients can share a read lease concurrently and there's an obvious potential benefit for file share performance in allowing caching on read-only access - is a shared LeasingMode an acceptable configuration from an ArcGIS perspective, or is it recommended that oplocks and leases should be disabled completely? 

0 Kudos
1 Solution

Accepted Solutions
ChristopherPawlyszyn
Esri Contributor

Hello James Brander‌ and Jan Sarata‌,

I think James and I had this conversation internally not too long ago, but wanted to also reiterate the information on here to help with similar questions in the future.

I can say that I've been running one of my test deployments off of a Windows 10 network share for about a year that has 'full' for the Leasing Mode value by default and have not experienced any negative effects in either Portal for ArcGIS or ArcGIS Server. This leads me to suspect the oplocks implementation in Windows Server 2008 R2/Windows 7 and previous versions was much more disruptive to our software than the newer implementation in SMB2/3 or we'd have a much larger prevalence of cases using default Windows network shares.

With that being anecdotal evidence that may not match every deployment's use case, I would suggest that the safest option for these deployments would be setting the Leasing Mode to 'none' to eliminate the possibility for adverse effects due to oplocks in the future if you'd prefer to proceed without testing the deployment directly.

Another aspect to keep in mind that NAS vendors can implement the SMB protocol slightly differently, so they would want to validate their workflows on that particular network storage before shifting their production deployments to that location regardless.

Hope that helps!

Chris


-- Chris Pawlyszyn

View solution in original post

2 Replies
JanSarata
Esri Contributor

Hello,

we are architecting a new ArcGIS Enterprise installation at High Availability mode and exactly this question, mentioned by James Brander‌, have just occurred.

So, is a shared LeasingMode an acceptable configuration from an ArcGIS perspective, or is it recommended that oplocks and leases should be disabled completely?

Thank you!

Jan Sarata

0 Kudos
ChristopherPawlyszyn
Esri Contributor

Hello James Brander‌ and Jan Sarata‌,

I think James and I had this conversation internally not too long ago, but wanted to also reiterate the information on here to help with similar questions in the future.

I can say that I've been running one of my test deployments off of a Windows 10 network share for about a year that has 'full' for the Leasing Mode value by default and have not experienced any negative effects in either Portal for ArcGIS or ArcGIS Server. This leads me to suspect the oplocks implementation in Windows Server 2008 R2/Windows 7 and previous versions was much more disruptive to our software than the newer implementation in SMB2/3 or we'd have a much larger prevalence of cases using default Windows network shares.

With that being anecdotal evidence that may not match every deployment's use case, I would suggest that the safest option for these deployments would be setting the Leasing Mode to 'none' to eliminate the possibility for adverse effects due to oplocks in the future if you'd prefer to proceed without testing the deployment directly.

Another aspect to keep in mind that NAS vendors can implement the SMB protocol slightly differently, so they would want to validate their workflows on that particular network storage before shifting their production deployments to that location regardless.

Hope that helps!

Chris


-- Chris Pawlyszyn