I have an old database application, which keeps all data in dbf's or
something similar. There are multiple clients working simultaneously. They all
share common database, which is stored on a Samba server.
By now I had only clients working on real Windows (98 and 2000). Everything
works perfect. Every instance is properly locking the shared database files, so
all clients are able to work at the same time, and nothing is corrupted. Samba
server seems to provide all necessary filesystem features. :-)
And now: I want to add some Wine-based clients. The database application seems
to work fine, but... file locking does not work. The files are being corrupted
if more than one instance run at the same time.
Actually this is a known problem:
http://forum.winehq.org/viewtopic.php?t=11407
http://forum.winehq.org/viewtopic.php?t=7387
And there is a known solution - to run all instances in the same wineserver (the
same wineprefix of the same user on the same computer). This solution does not
apply to me, because I do already have some Windows-based clients in my network.
I googled a little bit, and I found this:
http://wiki.winehq.org/FileLocking
This is the most interesting part:
> As much of the file locking as possible is done at the file system level,
but the only filesystem that supports the Windows style locking semantics is
smbfs. The rest we have to emulate in the wineserver.
It means, that actually... my application should work fine! I have Samba server!
The samba share is mounted by clients (Windows-based and now also Wine-based).
File locking on Windows-based clients works fine. According to the above quote,
I understand that file locking on Wine-based clients should also work fine. But
it does not...
Any ideas?
Maybe some mounting options are necessary? Some "special" registry
settings? Special Samba configuration? Anything else?