amrit pal pathak
2011-May-18 09:26 UTC
Address already in use - bind(2) (Errno::EADDRINUSE)
I made a new rails app and when i started the server ,it gave following error message. => Booting Mongrel => Rails 2.3.8 application starting on http://0.0.0.0:3000 => Call with -d to detach => Ctrl-C to shutdown server Exiting /usr/lib/ruby/1.8/mongrel/tcphack.rb:12:in `initialize_without_backlog'': Address already in use - bind(2) (Errno::EADDRINUSE) from /usr/lib/ruby/1.8/mongrel/tcphack.rb:12:in `initialize'' from /usr/lib/ruby/1.8/mongrel.rb:93:in `new'' from /usr/lib/ruby/1.8/mongrel.rb:93:in `initialize'' from /var/lib/gems/1.8/gems/rack-1.1.0/lib/rack/handler/mongrel.rb: 10:in `new'' from /var/lib/gems/1.8/gems/rack-1.1.0/lib/rack/handler/mongrel.rb: 10:in `run'' from /var/lib/gems/1.8/gems/rails-2.3.8/lib/commands/server.rb:111 from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require'' from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `require'' from script/server:3 Please help to resolve. Thanks. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Ankit Varshney
2011-May-18 09:36 UTC
Re: Address already in use - bind(2) (Errno::EADDRINUSE)
Hi Amrit, You cannot run two application on the same port. One of your application is already running using port 3000. And you are trying to run another application on the same port. If you want to run another application, then use the following command to do that: rub script/server -p 3001 where 3001 is the port number. You choose any other ports also. Ankit On Wed, May 18, 2011 at 2:56 PM, amrit pal pathak <amritpalpathak1-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> I made a new rails app and when i started the server ,it gave > following error message. > > > => Booting Mongrel > => Rails 2.3.8 application starting on http://0.0.0.0:3000 > => Call with -d to detach > => Ctrl-C to shutdown server > Exiting > /usr/lib/ruby/1.8/mongrel/tcphack.rb:12:in > `initialize_without_backlog'': Address already in use - bind(2) > (Errno::EADDRINUSE) > from /usr/lib/ruby/1.8/mongrel/tcphack.rb:12:in `initialize'' > from /usr/lib/ruby/1.8/mongrel.rb:93:in `new'' > from /usr/lib/ruby/1.8/mongrel.rb:93:in `initialize'' > from /var/lib/gems/1.8/gems/rack-1.1.0/lib/rack/handler/mongrel.rb: > 10:in `new'' > from /var/lib/gems/1.8/gems/rack-1.1.0/lib/rack/handler/mongrel.rb: > 10:in `run'' > from /var/lib/gems/1.8/gems/rails-2.3.8/lib/commands/server.rb:111 > from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in > `gem_original_require'' > from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `require'' > from script/server:3 > > > > Please help to resolve. > > Thanks. > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Talk" group. > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To unsubscribe from this group, send email to > rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > For more options, visit this group at > http://groups.google.com/group/rubyonrails-talk?hl=en. > >-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Peter De Berdt
2011-May-18 09:37 UTC
Re: Address already in use - bind(2) (Errno::EADDRINUSE)
On 18 May 2011, at 11:26, amrit pal pathak wrote:> I made a new rails app and when i started the server ,it gave > following error message. > > > => Booting Mongrel > => Rails 2.3.8 application starting on http://0.0.0.0:3000 > => Call with -d to detach > => Ctrl-C to shutdown server > Exiting > /usr/lib/ruby/1.8/mongrel/tcphack.rb:12:in > `initialize_without_backlog'': Address already in use - bind(2) > (Errno::EADDRINUSE) > from /usr/lib/ruby/1.8/mongrel/tcphack.rb:12:in `initialize'' > from /usr/lib/ruby/1.8/mongrel.rb:93:in `new'' > from /usr/lib/ruby/1.8/mongrel.rb:93:in `initialize'' > from /var/lib/gems/1.8/gems/rack-1.1.0/lib/rack/handler/mongrel.rb: > 10:in `new'' > from /var/lib/gems/1.8/gems/rack-1.1.0/lib/rack/handler/mongrel.rb: > 10:in `run'' > from /var/lib/gems/1.8/gems/rails-2.3.8/lib/commands/server.rb:111 > from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in > `gem_original_require'' > from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `require'' > from script/server:3 > > > > Please help to resolve.You already have a server running on port 3000. Probably another Webrick server you started earlier in a different terminal window. It even says so: Address already in use. I don''t see how it could be any more obvious. Best regards Peter De Berdt -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
amrit pal pathak
2011-May-20 14:03 UTC
Re: Address already in use - bind(2) (Errno::EADDRINUSE)
On May 18, 5:37 am, Peter De Berdt <peter.de.be...-LPO8gxj9N8aZIoH1IeqzKA@public.gmane.org> wrote:> On 18 May 2011, at 11:26, amrit pal pathak wrote: > > > > > > > > > > > I made a new rails app and when i started the server ,it gave > > following error message. > > > => Booting Mongrel > > => Rails 2.3.8 application starting onhttp://0.0.0.0:3000 > > => Call with -d to detach > > => Ctrl-C to shutdown server > > Exiting > > /usr/lib/ruby/1.8/mongrel/tcphack.rb:12:in > > `initialize_without_backlog'': Address already in use - bind(2) > > (Errno::EADDRINUSE) > > from /usr/lib/ruby/1.8/mongrel/tcphack.rb:12:in `initialize'' > > from /usr/lib/ruby/1.8/mongrel.rb:93:in `new'' > > from /usr/lib/ruby/1.8/mongrel.rb:93:in `initialize'' > > from /var/lib/gems/1.8/gems/rack-1.1.0/lib/rack/handler/mongrel.rb: > > 10:in `new'' > > from /var/lib/gems/1.8/gems/rack-1.1.0/lib/rack/handler/mongrel.rb: > > 10:in `run'' > > from /var/lib/gems/1.8/gems/rails-2.3.8/lib/commands/server.rb:111 > > from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in > > `gem_original_require'' > > from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `require'' > > from script/server:3 > > > Please help to resolve. > > You already have a server running on port 3000. Probably another > Webrick server you started earlier in a different terminal window. It > even says so: Address already in use. I don''t see how it could be any > more obvious.Is there any way to check,how many ports are already in use,so that i can stop the application which are already running on those.? Thanks -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Tom Meinlschmidt
2011-May-20 14:09 UTC
Re: Re: Address already in use - bind(2) (Errno::EADDRINUSE)
on linux - "lsof | grep -i ruby" tom On May 20, 2011, at 16:03 , amrit pal pathak wrote:> > > On May 18, 5:37 am, Peter De Berdt <peter.de.be...-LPO8gxj9N8aZIoH1IeqzKA@public.gmane.org> wrote: >> On 18 May 2011, at 11:26, amrit pal pathak wrote: >> >> >> >> >> >> >> >> >> >>> I made a new rails app and when i started the server ,it gave >>> following error message. >> >>> => Booting Mongrel >>> => Rails 2.3.8 application starting onhttp://0.0.0.0:3000 >>> => Call with -d to detach >>> => Ctrl-C to shutdown server >>> Exiting >>> /usr/lib/ruby/1.8/mongrel/tcphack.rb:12:in >>> `initialize_without_backlog'': Address already in use - bind(2) >>> (Errno::EADDRINUSE) >>> from /usr/lib/ruby/1.8/mongrel/tcphack.rb:12:in `initialize'' >>> from /usr/lib/ruby/1.8/mongrel.rb:93:in `new'' >>> from /usr/lib/ruby/1.8/mongrel.rb:93:in `initialize'' >>> from /var/lib/gems/1.8/gems/rack-1.1.0/lib/rack/handler/mongrel.rb: >>> 10:in `new'' >>> from /var/lib/gems/1.8/gems/rack-1.1.0/lib/rack/handler/mongrel.rb: >>> 10:in `run'' >>> from /var/lib/gems/1.8/gems/rails-2.3.8/lib/commands/server.rb:111 >>> from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in >>> `gem_original_require'' >>> from /usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `require'' >>> from script/server:3 >> >>> Please help to resolve. >> >> You already have a server running on port 3000. Probably another >> Webrick server you started earlier in a different terminal window. It >> even says so: Address already in use. I don''t see how it could be any >> more obvious. > Is there any way to check,how many ports are already in use,so > that i can stop the application which are already running on those.? > > Thanks > > -- > You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.-- Maxwell Render CZ Autorizovany distributor Maxwell renderu pro Ceskou republiku -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
> on linux - "lsof | grep -i ruby"I would like to recommend: lsof -i :3000 (given that the zombie server is running on port 3000) and then to check a reported <PID>: ps ax | grep <PID> before final: kill -QUIT <PID> -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
I agree with Peter De Berdt .. Another webrick server is still running Just close the shell and reopen it.. and then run ''rails server'' again -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/539a3e815327e718191fccded39b45fc%40ruby-forum.com. For more options, visit https://groups.google.com/groups/opt_out.
Fahad Idrees
2013-Nov-25 09:02 UTC
Re: Re: Address already in use - bind(2) (Errno::EADDRINUSE)
you can check which process is running on that port by typing on command line lsof -i tcp:port number and than kill that process by typing kill -9 process# and that start the rails server -p 3000 On Mon, Nov 25, 2013 at 2:15 AM, Agu N. <lists-fsXkhYbjdPsEEoCn2XhGlw@public.gmane.org> wrote:> I agree with Peter De Berdt .. > > Another webrick server is still running > > Just close the shell and reopen it.. > > and then run > > ''rails server'' again > > -- > Posted via http://www.ruby-forum.com/. > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Talk" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To view this discussion on the web visit > https://groups.google.com/d/msgid/rubyonrails-talk/539a3e815327e718191fccded39b45fc%40ruby-forum.com > . > For more options, visit https://groups.google.com/groups/opt_out. >-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CAJgx-djnd7e23pPKLr51xL0%3DOthf-UiGpKoED0MUm99UNG_cfw%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Colin Law
2013-Nov-25 11:19 UTC
Re: Re: Address already in use - bind(2) (Errno::EADDRINUSE)
On 25 November 2013 09:02, Fahad Idrees <access2coder-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> you can check which process is running on that port by typing on command > line > > lsof -i tcp:port number and than kill that process by typing > kill -9 process# > > and that start the rails server -p 3000 > > > On Mon, Nov 25, 2013 at 2:15 AM, Agu N. <lists-fsXkhYbjdPsEEoCn2XhGlw@public.gmane.org> wrote: >> >> I agree with Peter De Berdt .. >> >> Another webrick server is still runningDid you all realise you are responding to a post from 2011? Colin -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CAL%3D0gLvMKiFDg_Z-N0iaDeDPyeidD2bU4gZPUe5yVJK7WBw%3DjQ%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Tamara Temple
2013-Nov-26 03:45 UTC
Re: Address already in use - bind(2) (Errno::EADDRINUSE)
On Nov 25, 2013, at 5:19 AM, Colin Law <clanlaw-gM/Ye1E23mwN+BqQ9rBEUg@public.gmane.org> wrote:> On 25 November 2013 09:02, Fahad Idrees <access2coder-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: >> you can check which process is running on that port by typing on command >> line >> >> lsof -i tcp:port number and than kill that process by typing >> kill -9 process# >> >> and that start the rails server -p 3000 >> >> >> On Mon, Nov 25, 2013 at 2:15 AM, Agu N. <lists-fsXkhYbjdPsEEoCn2XhGlw@public.gmane.org> wrote: >>> >>> I agree with Peter De Berdt .. >>> >>> Another webrick server is still running > > Did you all realise you are responding to a post from 2011? > > ColinGmail Random Delivery strikes again! -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/1E4F26E7-BB7E-430A-A478-F61C547EF1A2%40gmail.com. For more options, visit https://groups.google.com/groups/opt_out.