restarting individual IN_ONESHOT rules

From: Euan Maxwell <euanmaxwell_at_gmail.com>
Date: Tue, 28 Apr 2009 10:25:48 +0100

Hi there,

I have a development scenario which incron is pretty much perfect for.

I want to watch a number of directories for new files coming in (via FTP).

Such an event will see potentially many files being uploaded over a
period of a few minutes. This is still classed as one event. I want
to perform a number of actions as soon as the first file hits.

Therefore, the IN_ONESHOT option is perfect for this.

However, I need to re-arm INDIVIDUAL IN_ONESHOT rules after a
pre-defined sleep period so as to not miss future events.

reloading the incrontab is not ideal as it will give me false
positives for any other upload events which are currently running (by
re-arming ALL IN_ONESHOT rules).

Is there a way to reload individual incrontab rules or would I be best
to handle re-setting the rules from within the script that I call or
some other mechanism?

Any thoughts as to how to handle this would be much appreciated. I'm
new to both incron and inotify in general.

Regards,

Euan.
Received on Tue Apr 28 2009 - 11:33:48 CEST

This archive was generated by hypermail 2.2.0 : Tue Jun 05 2012 - 22:14:21 CEST