On 01/04/2012 09:46 AM, Jim Meyering wrote: > Bernhard Voelker wrote: >> I stumbled over this readme sentence: >> >>> tail -f now uses polling (not inotify) when any of its file arguments >>> resides on a file system of unknown type. >> >> So I asked myself what happens if all file system types of all arguments >> are known but one is "remote"? strace gave the answer: in that case, >> tail uses polling for all arguments although it could use inotify for >> at least some of them. >> >> Is there a technical reason to do so, or is this just because the >> implementation would be more complicated? > > The implementation would be more complicated. > > However, as I wrote recently regarding distributed file systems, > tail -f may end up doing something smarter to accommodate them. > It could use inotify to handle local modifications, and polling > to catch changes that do not trigger inotify events.
Thanks for the clarification. > But even that feels like a tough call, unless the hybrid code > can somehow be very clean and simple. Would be the benefit even > be perceptible? To how many people? How often do people run tail -f > on a combination of local and non-local files? I agree. Have a nice day, Berny
