0

I need to analyze the file i/o operations caused due to a process. So I would like to know, which all files are affected by this program. Is there a tool for this particular use case?.

One of our debugging for a slow URL processing got the culprit being the file being read each time a URL was processed by the system. So I would like to get recommendations for a tool which would monitor the file activities per process. Any suggestions?

2 Answers2

1

You can use lsof with the -p flag, like this : lsof -p $PID .

schaiba
  • 131
  • 5
0

mainly you use ps for evaluating the pid of the process and use the proc filesystem to see the used files by the specific process. https://www.cyberciti.biz/faq/howto-linux-get-list-of-open-files/

Pierre.Vriens
  • 7,205
  • 14
  • 37
  • 84