lsof lists open files on a UNIX system. It is very useful in cases when it is necessary to find out what files are open and what’s going on in the system. lsof is very flexible.
The following list of command-line options shows that:
lsof 4.55 (latest revision at ftp://vic.cc.purdue.edu/pub/tools/unix/lsof) usage: [-?abChlnNoOPRstUvV] [-c c] [+|d s] [+|-D D] [+|-f[cfgGn]] [-F [f]] [-g [s]] [-i [i]] [-k k] [+|-L [l]] [-m m] [+|-M] [-o [o]] [-p s] [+|-r [t]] [-S [t]] [-T [t]] [-u s] [+|-w] [--] [names] Defaults in parentheses; comma-separate set (s) items; dash-separate ranges. -? | ...