how to release localhost from Error: listen EADDRINUSE

前端 未结 28 2180
孤独总比滥情好
孤独总比滥情好 2020-11-28 17:53

i am testing a server written in nodejs on windows 7 and when i try to run the tester in the command line i get the following error

Error: listen EADDRINUSE
         


        
28条回答
  •  生来不讨喜
    2020-11-28 18:14

    When you get an error Error: listen EADDRINUSE,

    Try running the following shell commands:

    netstat -a -o | grep 8080
    taskkill /F /PID 6204
    

    I greped for 8080, because I know my server is running on port 8080. (static tells me when I start it: 'serving "." at http://127.0.0.1:8080'.) You might have to search for a different port.

提交回复
热议问题