Resolving Responder Error: ‘Error Starting TCP Server on Port, Check Permissions or Other Servers Running.’
If you try to run Responder (or start any kind of listener) while a process is already running, you may have encountered this error:
[!] Error starting TCP server on port 389, check permissions or other servers running.
The actual port you see in the error message will correspond with the particular port you need to open. There may be multiple errors if several ports are already being used by other processes.
Resolving the Error
Depending on the command you use, it might be difficult to identify the actual PID of the process that already has the port open. I found that the following command always works for me:
sudo ss --tcp --udp --listen --numeric --process
In the response, identify the port in question and you should see the process name and ID of the process keeping that port open.
The following image shows that slapd is running on port 389, and it has a PID of 837.
That was the hard part. There are a variety of ways to kill a process. However, the kill command works well and is easy to remember:
sudo kill <pid>
In this case, we are killing slapd which has a PID of 837:
sudo kill 837
And that’s it! Now when you try running Responder, the error should be resolved.