lsofs
lsof, which stands for "list open files," is a command-line utility that displays information about files opened by processes. It is a powerful diagnostic tool for system administrators and developers, helping to identify which processes are using specific files, directories, network sockets, or devices. The output of lsof can be filtered by various criteria, including process ID (PID), user, file name, and network port.
When a program accesses a file, directory, socket, or other resource on a Unix-like operating system, that
Common use cases for lsof include troubleshooting "resource busy" errors, identifying which process is holding a