-1

How can I monitor in real time, which files an application reads and writes to while it is running? In my particular case I want to monitor korganizer.

Jeff Schaller
  • 67,283
  • 35
  • 116
  • 255
student
  • 18,305
  • 2
    Related: https://unix.stackexchange.com/q/58887/117549 and https://unix.stackexchange.com/q/13555/117549 – Jeff Schaller Oct 09 '19 at 18:38
  • Did you do any kind of searching? – Ken Sharp Oct 10 '19 at 00:59
  • Those answers are quite old, I think it might be worth reopening this as strace can have side-effects to the process it's tracing and nowadays there are kernel-based tools like ftrace, perfor systemtap that can achieve that without affecting the app. I would upvote this if the answer gets updated to specifically state this is to monitor reads/writes under Linux and without using strace. – Thomas Guyot-Sionnest May 08 '22 at 16:57

1 Answers1

1

So many ways, see the man pages for each of these:

Start the program under strace, and use strace options to only see the file operations you care about.

Download the source for installwatch, and adapt.

Repeated lsof -c korganizer.

waltinator
  • 4,865