On Sun, Jun 15, 2008 at 09:41:44AM -0700, Sage Weil (sage@newdream.net) wrote:First, socket has own internal lock, which protects against simultaneous access to its structures, but POHMELFS has own mutex, which guards network operations for given network state, so if server disconnected, socket can be released and zeroed if needed, so that subsequent access could detect it and made appropriate decision like try to reconnect. I really do not understand your surprise :) But it does possible to create a scheme, when you do not need to hold a lock between commands for successfull complete. It is even possible not to _expect_ that something will be received from given socket or received at all. Courtesy of transactions: system locks only data, which has to be processed, it does not lock sequence of commands which are required for that data processing. Ordering is guarded by transactions. Local inode number is returned. Inode number does not change during lifetime of the inode, so while it is alive always the same number will be returned. No, since it got a reference to object in local cache. But it will fail to do something interesting with it, since it does not really exist on server anymore. When 'hosta' will reread higher directory (it will when needed, since server will send it cache coherency message, but thanks to your example, rename really does not send it, only remove :), so I will update server), it will detect that directory changed its name and later will use it. After reread system actually can not know if directory was renamed or it is completely new one with the same files. You pointed to very interesting behaviour of the path based approach, which bothers me quite for a while: since cache coherency messages have own round-trip time, there is always a window when one client does not know that another one updated object or removed it and created new one with the same name. It is trivially possible to extend path cache with storing remote ids, so that attempt to access old object would not harm new one with the same name, but I want to think about it some more. Correct solution is to use locks of course, and I'm not 100% it worse changing at all without them, but it is interesting... -- Evgeniy Polyakov --
| H. Peter Anvin | Re: [RFC 00/15] x86_64: Optimize percpu accesses |
| Greg Kroah-Hartman | [PATCH 008/196] Chinese: add translation of volatile-considered-harmful.txt |
| Greg KH | Re: Dual-Licensing Linux Kernel with GPL V2 and GPL V3 |
| Alex Chiang | [PATCH 1/4] Remove path attribute from sgi_hotplug |
git: | |
| Jarek Poplawski | [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
| Gerrit Renker | [PATCH 27/37] dccp: Integration of dynamic feature activation - part 2 (server side) |
| David Miller | Re: [GIT]: Networking |
| Eric Dumazet | Re: [PATCH 3/3] Convert the UDP hash lock to RCU |
