Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

Possible Duplicate:
Can a bash script be hooked to a file?

Is it possible to mount a mechanism to a file to perform an action (e.g. mark the change in some log file and such) each time the file is modified? I would like to be able to see what all the files modified are in a given time period or receive an alert each time someone modifies a file.

share|improve this question
    
Probably the linux audit daemon (auditd) can be used for this. –  TAFKA 'goldilocks' Dec 7 '12 at 18:22
add comment

marked as duplicate by Gilles, Renan, jasonwryan, warl0ck, manatwork Dec 8 '12 at 16:30

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

1 Answer

up vote 5 down vote accepted

You can use incron for this if your os and filesystem support inotify.

share|improve this answer
    
I am on RHEL 5.8 -- do have a man page for inotify but couldn't find the exe in the path –  amphibient Dec 7 '12 at 18:22
1  
RHEL doesn't ship it, so you need to install it yourself. –  Dennis Kaarsemaker Dec 7 '12 at 18:25
add comment

Not the answer you're looking for? Browse other questions tagged or ask your own question.