So im using ruby on rails in windows (i hear you all spitting your coffee onto the screen), its only a short term thing. (using ubuntu at home) So i tried to fire up webrick this afternoon and i get the error message
TCPServer Error, only one usage of each socket address is normally permitted
So it seems as if port 3000 is still running from last week? My question is how do i kill the process from the Windows command line. normally i have to press ctrl and pause/break in windows as ctrl c is not working which is only killing the batch process it seems..
Any solutions welcomed
Edit
So it seems as if
tasklist
will give me the list of processes, but where do i find the process for running the webrick server?
ruby.exe
is not listed as a running process
Try using
netstat -a -o -n
to determine thepid
of the process running on port 3000. Then you should be able to usetaskkill /pid ####
to kill whatever process is running on that port.Probably not the most graceful way to do it, but I think it should work.
EDIT
You'll probably have to also use the
/F
flag to force-kill the process. I just tried it on my local machine, and that worked fine.Go into
rails_project\tmp\pids
and delete the .pid file in there.run: