Mailcatcher Error: ~~> ERROR: Something's usin

2019-07-25 08:48发布

问题:

I have installed the gem mailcatcher. And when I want to run the mailcatcher I have this error message:

$ mailcatcher
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::BASE
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of BASE was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::EXCEPTION_ALL
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of EXCEPTION_ALL was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::EXCEPTION_NaN
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of EXCEPTION_NaN was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::EXCEPTION_INFINITY
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of EXCEPTION_INFINITY was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::EXCEPTION_UNDERFLOW
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of EXCEPTION_UNDERFLOW was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::EXCEPTION_OVERFLOW
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of EXCEPTION_OVERFLOW was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::EXCEPTION_ZERODIVIDE
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of EXCEPTION_ZERODIVIDE was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::ROUND_MODE
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of ROUND_MODE was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::ROUND_UP
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of ROUND_UP was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::ROUND_DOWN
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of ROUND_DOWN was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::ROUND_HALF_UP
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of ROUND_HALF_UP was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::ROUND_HALF_DOWN
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of ROUND_HALF_DOWN was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::ROUND_CEILING
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of ROUND_CEILING was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::ROUND_FLOOR
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of ROUND_FLOOR was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::ROUND_HALF_EVEN
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of ROUND_HALF_EVEN was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::SIGN_NaN
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of SIGN_NaN was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::SIGN_POSITIVE_ZERO
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of SIGN_POSITIVE_ZERO was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::SIGN_NEGATIVE_ZERO
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of SIGN_NEGATIVE_ZERO was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::SIGN_POSITIVE_FINITE
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of SIGN_POSITIVE_FINITE was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::SIGN_NEGATIVE_FINITE
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of SIGN_NEGATIVE_FINITE was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::SIGN_POSITIVE_INFINITE
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of SIGN_POSITIVE_INFINITE was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::SIGN_NEGATIVE_INFINITE
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of SIGN_NEGATIVE_INFINITE was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::INFINITY
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of INFINITY was here
/Users/romenigld/.rvm/gems/ruby-2.2.3@global/extensions/x86_64-darwin-14/2.2.0-static/bigdecimal-1.2.7/bigdecimal.bundle: warning: already initialized constant BigDecimal::NAN
/Users/romenigld/.rvm/rubies/ruby-2.2.3/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:121: warning: previous definition of NAN was here
Starting MailCatcher
~~> ERROR: Something's using port 1025. Are you already running MailCatcher?

Then when I try to use the http://localhost:1080/ shows me the app mailcatcher. But what I need to do with the application for don't show anymore this error?

回答1:

Something seems to be running on that port. It can be another instance of mailcatcher, or some other process.

On most *nix systems you can use the following command to search for a process occupying a particular port:

lsof -i :PORT

For example:

lsof -i :1025

The result will contain a PID (Process ID). You can use this to kill the offending process.

kill -9 SOME_PID

Example:

kill -9 32487