Filesystem monitoring¶
Of course. Whenever you look for a solution you don’t find it. If you’ve fixed something already, then you easily find another five solutions for it.
My problem was that I wanted to monitor all read-accesses to my music so I can see afterwards what I was listening to.
I’ve fixed this in the meantime with a parameter of MOCP (my main player), so it writes all played files into a central log file. That way I can see at the end of the year what I was listening to and how often.
Now, after this issue has been resolved for a couple of weeks, possible solutions strike me day by day.
The first one would be the Linux kernel 2.6 built in auditd daemon. Haven’t really tried that solution, but it might work.
The second solution (which I’ve actually tested) is the logsyncd daemon for syncing files. It monitors whatever action you want in a file and can trigger basically every action you want. Not necessarily only syncing the file, but also just writing a log.
Try it out…