Error  that port is already in use.

Error that port is already in use.

How to resolve “port already in use” error using netstat

On October 5, 2016, MSDN published the first version of this article. You get the dreaded phone call at 3 a.m. on a Saturday morning – “The SQL Server was recently serviced. We rebooted, and SQL now refuses to start “!! When you look at the error logs, you’ll find something like this: spidxxs spidxxs spidxxs spidxxs spidxxs spidxxs spidxxs spidxx TCP provider on the server failed to listen on [‘any’ ipv6> 1433]. The TCP port is currently in use. spidxxs spidxxs spidxxs spidxxs spidxxs spidxxs spidxxs spidxx State: 1, Error: 17182, Severity: 16, Error: 17182, Error: 17182, Error: 17182, Er You know no providers were using your port before the maintenance, so what’s up and how do you figure out who is using SQL’s port? This error message will appear in one of two cases. The first and most apparent scenario is when another service or application on the server uses the same TCP port as SQL Server. That would be tcp/1433, in the example above. By running the command, you can easily decide which process is using the port.

[solved] error: that port is already in use.

ERROR: gotoconsult adminer has encountered an error. Error beginning userland proxy: listen tcp 0.0.0.0:8089: bind: address already in use (06771e791ffbd3a04af81f13f8a6a885c9dd11e8031aa34bb9a2a037fbfdfc3e):
ERROR: for the administrator Error beginning userland proxy: listen tcp 0.0.0.0:8089: bind: address already in use (06771e791ffbd3a04af81f13f8a6a885c9dd11e8031aa34bb9a2a037fbfdfc3e):
ERROR: gotoconsult adminer has encountered an error. Cannot start service adminer: driver failed programming external connectivity on endpoint gotoconsult adminer (aafcc2af19f6589c62586dbc3b9c57562b6416f7500cdf0b40a37052d138da3b): Error starting userland proxy: bind: address already in use (aafcc2af19f6589c62586dbc3b9c57562
ERROR: for the administrator Error starting userland proxy: listen tcp 0.0.0.0:8089: Cannot start service adminer: driver failed programming external communication on endpoint gotoconsult adminer (aafcc2af19f6589c62586dbc3b9c57562b6416f7500cdf0b40a37052d138da3b): bind: already in use address

How netstat command can help in port already in use error

This error normally suggests that I need to interrupt a duplicate server. However, I’ve recently had issues with Gatsby not completely shutting down when the server was stopped. Despite the fact that the web server was not running, the port was still being used. And I didn’t know how to terminate the process that was running on the port.
That concludes our discussion. Since npx must temporarily install the kill-port kit, it is slower than kill + lsof. However, it is 1000x easier for me to recall. I looked through the source code for kill-port, and sure enough, the package uses kill + lsof! In my view, the kill-port kit actually offers a more approachable abstraction.

Error: that port is already in use when attempt to running

This happens to me because a debugger breakpoint in my app intercepts my API request in Postman, leaving the request hanging. The error does not occur if I cancel the request in Postman before destroying the server for my app.
When I forget to cancel the open http request on macOS, I use sudo lsof -t -i tcp:8000 | xargs kill -9 to solve the error = The port is already in use. This also closes my Postman app completely, which is why my first option is preferable.
It appears that IDEs, such as VSCode, Puppeteer, nodemon, express, and others, trigger this issue, or that you simply closed the debugging area [browser, terminal, etc.]. or whatever; in any case, I’ve already answered the same question.
Simply pick another shell from the dropbox to the left of the + sign in the header of the VSC terminal and see if the server is still running there. You can now exit the server and begin working on a new one.

About the author

admin

View all posts