Evgeniy Polyakov wrote:
Oplocks and leases are essentially lock on given file, which allows one client to operate on it. POHMELFS does not have locks now, and they will be created depending on how distributed server will require them. In the simplesst case it can just lock file for writing and do not allow its updates from other clients. Lock aciquite can be done at write_begin time. Without lock and writeback cache in your case writeback for file Y can happen before writeback for file X, but if client does not only write, but also sync after its write, then yes, client will see later updates after more earlier. POHMELFS does not broadcast its interest in the file content until real writing happens, i.e. at writeback time. Although I can add a mode, when the same will be done during write_begin() time. In that case your example will work without sync.
For /locking/, life is easy, you don't have to worry about disallowing client updates, because locking is advisory. However, there are some guarantees you need for locking WRT write commit, and of course leases are a totally different animal where you do block client updates.
Jeff -- To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html