Samba synchronization
Well, i'm doing kind of a research on file storage synchronization. It's a common topic with a spicy touch. I've got a VPN between two offices, one of the offices is running a samba fileserver and is running fine , i've bridged the VPN so that the users on both sides of the vpn can see each other(they share the same broadcast segment after all).
Office 1 physically has a file server, Office 2 has a fileserver logically over the VPN. Here comes the problem - Office 1 has a broadband connection , but Office 2 is on some ADSL and it's upload capabilities are too limited for comfortable work.It's like capped to 128kbps upload and 1mbps down. I can't get over that speed limit, because of geo restrictions. I've decided to put another fileserver in Office-2 and have it synchronized with Office-1's fileserver and vice-versa. Background synchronization is better that waiting 30 minutes to save your excel sheet and i can imply compression. Off-line synchronization is done fine either with some rsync wrappings or unison, but still data concurrency has to be kept. I can't afford to have just-saved files to be overwritten. So i'm onto writing a daemon for both of the servers listening for commands and casting flock()(on deepfs level, not nfs/smbfs implementations) or fcntl()'s whenever a file is locked on any side of the "array".
I've already learned the VFS hooking and it's not a problem to do it. With the event-based interface from that VFS-ing i can do it easy and reliable.
After 'at tirade of words, i'm wondering - is there any better solution for samba synchronization or doing a custom solution is appropriate.
|