I have a set-up a server running several applications. There will be multiple people using these applications in a community situation. I am looking for a way to track and report changes made to certain files and dirs. There is already a MTA setup, so I am looking for a way to generate logs of activity on specified locations and then mail them once a day. Can anyone offer any advice on where to start?
If you know the processes that you want to monitor then you can use "lsof" command to see the file a particular process or command is using. Please see below for an example :
$$ lsof -p "pid_of_process"
Even if you do not know about process then also you can use lsof periodically to collect system information about files used by a process.
If you are interested in complete system activity, then "sar" utility should be used