A tiny utility to determine which process is currently using a given port.
This will run on Unix machines (anywhere that lsof
exists)
If you have go, you can run
go install github.com/bluehoodie/whoseport@latest
Or download and build from source:
git clone https://github.com/bluehoodie/whoseport;
cd whoseport;
make install
If you do not have go, downloads will be available shortly.
Example:
$ whoseport 8080
Will output something like
{
"command": "foo",
"id": 325,
"user": "colin",
"fd": "7u",
"type": "IPv6",
"device": "0x5e4b104643390241",
"size_offset": "0t0",
"node": "TCP",
"name": "*:http-alt (LISTEN)"
}
See the LICENSE file for details
This project is certainly not the first of its kind. Many before have made utilities such as this, or have created aliases which give roughly the same output.
This was borne of a simple idea to write a version in Go with a pretty output.