Rafael Reyes
Rafael Reyes

Reputation: 2655

WebBrick rails server error

Can someone tell me why I'm having this erro..?! when I rul the comand rails s and I've been trying to run it in several ports and still don't work!

enter image description here

Booting WEBrick
=> Rails 4.0.1 application starting in development on http://0.0.0.0:3000
=> Run `rails server -h` for more startup options
=> Ctrl-C to shutdown server
[2014-02-11 11:32:26] INFO  WEBrick 1.3.1
[2014-02-11 11:32:26] INFO  ruby 1.9.3 (2013-11-22) [i386-mingw32]
[2014-02-11 11:32:26] WARN  TCPServer Error: Only one usage of each socket address (protocol/network address/port) is normally permitted. - bind(2)
Exiting
C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/webrick/utils.rb:85:in `initialize': Only one usage of each socket address (protocol/network address/port) is normally permitted. - bind(2)
(Errno::EADDRINUSE)

Upvotes: 0

Views: 549

Answers (2)

Prabhakaran8737
Prabhakaran8737

Reputation: 81

Try to find and kill the process that rails uses

lsof -wni tcp:3000
kill -9 PID

Upvotes: 0

nikolayp
nikolayp

Reputation: 17939

The previous server was not terminate properly, thus you can run server on different port(or kill previous rails proces) as you wish:

bundle exec rails s -p 3001

Upvotes: 2

Related Questions