fuser

Display process IDs currently using files or sockets. More information: https://manned.org/fuser.

fuser {{path/to/file_or_directory}}

fuser {{[-v|--verbose]}} {{path/to/file_or_directory}}

fuser {{[-n|--namespace]}} tcp {{port}}

fuser {{[-k|--kill]}} {{path/to/file_or_directory}}

fuser {{[-m|--mount]}} {{path/to/file_or_directory}}

fuser {{[-k|--kill]}} {{port}}/tcp