网络文件锁定的可靠性 [英] Reliability of file locking on network files

查看:118
本文介绍了网络文件锁定的可靠性的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我读取网络文件上的文件锁定不是很可靠



我正在使用这些LockFile / LockFileEx / UnlockFile win32-api函数来进行范围锁定。有没有人有一些使用网络共享文件上的这些功能的经验?解决方案

他们完成了一个远程CIFS份额。有很多平面文件数据库,使用这些机制已经有数十年的可靠性。



如果在远程NFS共享上完成,它们是不可靠的吉姆·刘易斯提到)。


I read that file locking on network files isn't very reliable.

I'm using those LockFile/LockFileEx/UnlockFile win32-api functions for range-locks. Does anyone have some experience of using those functions on files living on a network-share?

解决方案

Win32 file locking mechanisms are reliable IF they're done to a remote CIFS share. There have been many flat file databases that work just quite reliably using these mechanisms for decades.

They're not reliable if they're done on a remote NFS share (as Jim Lewis mentioned).

这篇关于网络文件锁定的可靠性的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆