Linux Tools – incron, the “File-Change Cron”

incron :: inotify cron system

As a technically-minded Linux user, I’m very familiar with the cron daemon. However, like any good UNIX/Linux tool, it does one job and does it well: Running things at specific times. It’s of no use to me for tasks which should be run when a file or directory changes.

Thankfully, I just discovered "incron". The "inotify cron system". inotify is a Linux kernel feature added in the last year or so which allows programs to monitor files and folders for various events with minimal overhead and incron takes advantage of that to provide a simple way to run tasks in response. As another nice design feature, incron is designed to be as familiar to cron users as possible.

It’s still a little rough (for example, you can’t put comments into your incrontab and it won’t resolve ~ to mean your homedir), but all-in-all, a useful and nifty little tool.

CC BY-SA 4.0 Linux Tools – incron, the “File-Change Cron” by Stephan Sokolow is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

This entry was posted in Geek Stuff. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

By submitting a comment here you grant this site a perpetual license to reproduce your words and name/web site in attribution under the same terms as the associated post.

All comments are moderated. If your comment is generic enough to apply to any post, it will be assumed to be spam. Borderline comments will have their URL field erased before being approved.