JSI Tip 8997. You experience significant delays when opening files over the network in a multi-user application?

Jerold Schulman

January 31, 2005

1 Min Read
ITPro Today logo in a gray background | ITPro Today

When the Server Service receives a request for a file that is already open, it may receive a sharing violation. The Server Service then waits before retrying the operation a number of times.

NOTE: This behavior is readily apprent with any multi-user, file-based application, such as the Jet database engine that has shared database files.

Using REG.EXE on Windows 2000, from the Windows 2000 Support Tools, or REG.EXE built into Windows XP, Windows Server 2003, and later operating systems, AND PsShutdown.exe, I have scripted NTOptOff.bat to resolve this behavior.

The syntax for using NTOptOff.bat is:

NTOptOff [R]

Where the optional parameter R will restart your computer.

NOTE: A restart is required for these settings to become effective.

NOTE: See How can I improve Access or Jet database performance on Windows Server 2003?

NTOptOff.bat contains:

@echo offsetlocalset sd=%1set key="HKLMSYSTEMCurrentControlSetServicesLanmanServerParameters"call :quiet>nul 2>&1if /i {%sd%} NEQ {R} endlocal&goto :EOFendlocalPsShutdown -r -f:quietreg add %key% /V SharingViolationDelay /T REG_DWORD /F /D 0reg add %key% /V SharingViolationRetries /T REG_DWORD /F /D 0



Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.

You May Also Like