Automatic File Locking in the Egnyte Connect Desktop App


When a user opens a file using the Egnyte Connect Desktop App, the file is automatically locked in the cloud to prevent other users from overwriting changes. Other users who attempt to open or edit the file will receive a notification that the file is locked for editing and can still view the file in read-only mode.

DA_windows_file_locking.png       DA_mac_file_locking.png

The file locking mechanism also reduces the chance of conflicts occurring.

Unsupported Applications and Files

The automatic locking mechanism is not supported for applications which immediately close a file after its contents are loaded into memory. Though a user would see the file as open in such applications, the Desktop App would receive a notification from the system that the file was opened and immediately closed. In such cases, Egnyte's conflict detection mechanism would still be able to detect conflicts between multiple users.

Below are examples of file types and applications for which the file locking mechanism cannot be supported due to the behavior described above:

  • Adobe Illustrator (.ai)
  • Adobe Photoshop (.psd)


I opened a file from one computer but I can still edit it from another computer where I'm logged in. How is that possible if the file is locked?

Every lock is tied to a specific user so it prevents other users from editing the file. If you log in using the same account that holds the lock from a different computer, you can still edit the files, but other users will only be able to read contents of the file.

How does the Desktop App determine when a file should be locked?

When a user opens a file with an application, the application opens a special handle on the file to let other applications know that it has the file open. We use this to determine when to lock to file. We only lock the file up to 5 seconds after the handle is opened and remains open to handle cases where applications frequently open and close files in short succession.

How does the Desktop App know how long files should remain locked?

A file will remain locked as long as the application which was used to open the file maintains an open handle on the file AND the user has an internet connection.

We achieve this by creating locks that last for 6 minutes in the cloud. In the 90 seconds before the lock is due to expire, we attempt to renew the lock for another 6 minutes. We repeat this process as long as the file is open by an application.

When is a file unlocked in the cloud?

Files are unlocked if any of the following occur:

  • The application closes the handle on the file to indicate it is no longer using the file.
  • If there is no connection to the cloud during the 90 second period when we attempt to renew the lock. This could be either due to the machine getting shut down, going into hibernation, or internet access being lost.

How does global file locking work with applications that used linked or cross-referenced files (e.g. Adobe InDesign or AutoCAD)?

In applications with linked files, users will typically open a master file that links to multiple files or assets. Linked files are usually loaded into memory and then immediately closed by the application but there are cases where assets are also held open as long as the master file is open. In most situations, the master file is locked since it is held open by the application and the linked assets are not locked so they can be opened and modified by other users. However, this behavior can vary from application to application.

Egnyte Community

Egnyte Community

Want to connect with other Egnyte users and our Egnyte team? Share ideas and ask questions in our Community .