0

I've tried to kill my rails server using this article from cloud 9.

I'm using the gem thin and everytime I try to run cloud server command I recieve this error

rails s -b $IP -p $PORT
=> Booting Thin
=> Rails 4.2.6 application starting in development on http://0.0.0.0:8080
=> Run `rails server -h` for more startup options
=> Ctrl-C to shutdown server
Thin web server (v1.6.4 codename Gob Bluth)
Maximum connections set to 1024  
Listening on 0.0.0.0:8080, CTRL+C to stop
Exiting
/usr/local/rvm/gems/ruby-2.3.0/gems/eventmachine-1.2.0.1/lib/eventmachine.rb:530:in `start_tcp_server': no acceptor (port is in use or requires root privileges) (RuntimeError)
    from /usr/local/rvm/gems/ruby-2.3.0/gems/eventmachine-1.2.0.1/lib/eventmachine.rb:530:in `start_server'
    from /usr/local/rvm/gems/ruby-2.3.0/gems/thin-1.6.4/lib/thin/backends/tcp_server.rb:16:in `connect'
    from /usr/local/rvm/gems/ruby-2.3.0/gems/thin-

full error

dp7
  • 6,651
  • 1
  • 18
  • 37
leafshinobi25
  • 67
  • 2
  • 6

2 Answers2

0

This error says, 8080 port already in use, you may need to use different port for you application

Update:

Try to kill the existing process. Find port number using this command ps -ef | grep thin and then kill it kill -9 <port>. Try running your app now.

Raj Adroit
  • 3,828
  • 5
  • 31
  • 44
0

It seems the port 8080 is in use, to find the PID using the port, run :

netstat -tulpn | grep :8080

Then you can kill -9 <PID>

Abdoo Dev
  • 1,216
  • 11
  • 16