lsof is a tool to list open files of processes

This command line tool exists on most UNIX-like operating systems and lists open files along with the processes that opened them.