Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
698 views
in Technique[技术] by (71.8m points)

visual studio - Unable to launch the ASP.NET Development server because port '1900' is in use

I was developing just fine in VS 2008 and testing my ASP.NET web site on my development server when suddenly I was unable to run my web site anymore. As soon as I hit F5, the message appears:

Unable to launch the ASP.NET Development server because port '1900' is in use.

It doesn't matter what port I change to, it's always in use. I have tried:

  • Changing the port number
  • Restarting Visual Studio
  • Rebooting my machine
  • Installing IIS

Clue: My IIS refuses to start. But I didn't have IIS installed when I was happily working earlier, so that is probably not the issue; it might just be highlighting something else.


Update: after rebooting, IIS does start, but the problem here persists.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Simply end all Webdev.WebServer.exe processes - did the trick for me. Occasionally this 'unable to launch because port is in use' error happens when one of the visual studio processes (webdev.webserver.exe) is still running and locked. The webdev.webserver process(s) should end when you close your browser or app but if they dont (for instance my Visual Studio crashed but if left the webserver still running) then this could lock the port and this will prevent visual studio from launching your project. When you try to F5 your app (launch your application from visual studio) then it conflicts with the current port in use and the above 'because port XYZ is in use' error is displayed.

So to fix it: in the status bar (next to your windows clock) right-click and 'Stop' all the ASP.net development server icons. You can also open task manager and kill all the webdev.webserver.exe processes.

enter image description here


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...