From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756608AbYKVHMg (ORCPT ); Sat, 22 Nov 2008 02:12:36 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752738AbYKVHM1 (ORCPT ); Sat, 22 Nov 2008 02:12:27 -0500 Received: from hawking.rebel.net.au ([203.20.69.83]:33535 "EHLO hawking.rebel.net.au" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752664AbYKVHM0 (ORCPT ); Sat, 22 Nov 2008 02:12:26 -0500 Message-ID: <4927B0D5.4020907@davidnewall.com> Date: Sat, 22 Nov 2008 17:42:21 +1030 From: David Newall User-Agent: Thunderbird 2.0.0.12 (X11/20080227) MIME-Version: 1.0 To: Evgeniy Polyakov CC: linux-api@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [take 3] Use pid in inotify events. References: <20081120230612.GB6536@ioremap.net> <200811211939.46812.arnd@arndb.de> In-Reply-To: <200811211939.46812.arnd@arndb.de> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Friday 21 November 2008, Evgeniy Polyakov wrote: > I have a network server, which gets IO requests from different clients > and maintains coherency of the data between them, but if file is > modified locally I want to flush or invalidate remote data. I decided > not to dig into the kernel on the server node and use inotify to get > notifications about events, but there is no way to determine if given IO > was originated by server itself (and in this case nothing should be > done), or by external application which accesses exported directory (and > in this case I should send update messages to clients). Why not require local access to use the same mechanism as remote, i.e. by "network mounting" the data on the local machine, too. That way there's no confusion over where the change originated nor who's copy must be invalidated.