Re: [Patch][RFC] fcntl: add ability to stop monitored processes

From: Neil Horman
Date: Mon Jun 13 2005 - 08:50:10 EST


On Mon, Jun 13, 2005 at 08:13:04AM +0200, Arjan van de Ven wrote:
> On Sun, 2005-06-12 at 14:10 -0400, Neil Horman wrote:
> > How about this? Its the same feature, with an added check in fcntl_dirnotify to
> > ensure that only processes with CAP_SYS_ADMIN set can tell processes preforming
> > the monitored actions to stop.
>
> SIGSTOP is kinda rude I think though..... I mean, how do you suppose you
> restart said processes again? manual sysadmin work?
>
The idea I had was to catch processes which are preforming ostensibly
undesireable filesystem operations (as defined by the actions that F_NOTIFY can
monitor). I'm not sure how else to avoid the race condition that can arise
between the delivery of the F_NOTIFY signal to the monitoring process, and the
exiting of the monitored process. If you have another thought, I'm certainly
open to it.

Re: restarting processes. If a sysadmin wants to manually resart stopped
processes, that would certainly be an option. My thought was that the
monitoring process could do it in code. notice this patch also delivers the pid
of the stopped process in si_pid to the process receiving the signal.

Regards
Neil

--
/***************************************************
*Neil Horman
*Software Engineer
*Red Hat, Inc.
*nhorman@xxxxxxxxxx
*gpg keyid: 1024D / 0x92A74FA1
*http://pgp.mit.edu
***************************************************/
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/