listen EADDRINUSE: address already in use Exception

listen EADDRINUSE: address already in use Exception

Exception:

Error: listen EADDRINUSE: address already in use Exception

Resolution:

Application running the PORT should be killed.

For Windows OS, use the following commands to find the PID to kill the application running on a Port Number.

To find the PID:

Syntax:

netstat -ano | findstr :<PORT_NUMBER>

Example:

netstat -ano | findstr :3030

To kill the application:

Syntax:

taskkill /PID <PID> /F

Example:

taskkill /PID 2076 /F

/F is for quitting the application forcefully.

PID is Process Identifier.

Leave a Reply