heroku h10 app崩溃 - 超时

时间:2015-12-02 18:27:32

标签: ruby-on-rails ruby-on-rails-4 heroku crash sidekiq

我在heroku上遇到了这种崩溃 - 我在heroku和aptible上运行这个应用程序,并试图保持代码库相同;但似乎在heroku上它不断重启/超时连接到sidekiq?

2015-12-01T02:53:17.862788+00:00 heroku[worker.1]: State changed from up to down
2015-12-01T02:53:17.865206+00:00 heroku[worker.1]: State changed from down to starting
2015-12-01T02:53:23.970560+00:00 heroku[worker.1]: Starting process with command `bundle exec sidekiq -q default -q events -q summaries -c 5 -v`
2015-12-01T02:53:24.596328+00:00 heroku[worker.1]: State changed from starting to up
2015-12-01T02:53:33.158209+00:00 app[worker.1]: 3 TID-out3bksa0 INFO: Running in ruby 2.1.6p336 (2015-04-13 revision 50298) [x86_64-linux]
2015-12-01T02:53:33.158223+00:00 app[worker.1]: 3 TID-out3bksa0 INFO: See LICENSE and the LGPL-3.0 for licensing details.
2015-12-01T02:53:33.158249+00:00 app[worker.1]: 3 TID-out3bksa0 INFO: Upgrade to Sidekiq Pro for more features and support: http://sidekiq.org
2015-12-01T02:53:33.158337+00:00 app[worker.1]: 3 TID-out3bksa0 DEBUG: Middleware: Sidekiq::Middleware::Server::Logging, Sidekiq::Middleware::Server::RetryJobs, Sidekiq::Middleware::Server::ActiveRecord, NewRelic::SidekiqInstrumentation
2015-12-01T02:53:33.158562+00:00 app[worker.1]: 3 TID-out3bksa0 INFO: Booting Sidekiq 3.5.0 with redis options {:url=>"redis://redistogo:REDACTED@herring.redistogo.com:9015/"}
2015-12-01T02:53:33.158929+00:00 app[worker.1]: 3 TID-out3bksa0 INFO: Starting processing, hit Ctrl-C to stop
2015-12-01T02:53:33.161928+00:00 app[worker.1]: 3 TID-out493vp0 DEBUG: {:queues=>["default", "events", "summaries"], :labels=>[], :concurrency=>5, :require=>".", :environment=>nil, :timeout=>8, :poll_interval_average=>nil, :average_scheduled_poll_interval=>15, :error_handlers=>[#<Sidekiq::ExceptionHandler::Logger:0x007f8c968e02e0>], :lifecycle_events=>{:startup=>[], :quiet=>[], :shutdown=>[]}, :dead_max_jobs=>10000, :dead_timeout_in_seconds=>15552000, :verbose=>true, :strict=>true, :tag=>"app"}
2015-12-02T03:21:37.228034+00:00 heroku[worker.1]: Cycling
2015-12-02T03:21:37.228738+00:00 heroku[worker.1]: State changed from up to starting
2015-12-02T03:21:42.240351+00:00 heroku[worker.1]: Stopping all processes with SIGTERM
2015-12-02T03:21:43.002210+00:00 heroku[worker.1]: Starting process with command `bundle exec sidekiq -q default -q events -q summaries -c 5 -v`
2015-12-02T03:21:43.662178+00:00 heroku[worker.1]: State changed from starting to up
2015-12-02T03:21:43.667277+00:00 app[worker.1]: 3 TID-out3bksa0 DEBUG: Got TERM signal
2015-12-02T03:21:43.669386+00:00 app[worker.1]: 3 TID-out3bksa0 INFO: Shutting down
2015-12-02T03:21:44.068341+00:00 app[worker.1]: 3 TID-out493vp0 INFO: Terminating 5 quiet workers
2015-12-02T03:21:45.309958+00:00 heroku[worker.1]: Process exited with status 0
2015-12-02T03:21:56.259541+00:00 app[worker.1]: 3 TID-owx1o19n8 INFO: Booting Sidekiq 3.5.0 with redis options {:url=>"redis://redistogo:REDACTED@herring.redistogo.com:9015/"}
2015-12-02T03:21:56.262694+00:00 app[worker.1]: 3 TID-owx2m7rqw DEBUG: {:queues=>["default", "events", "summaries"], :labels=>[], :concurrency=>5, :require=>".", :environment=>nil, :timeout=>8, :poll_interval_average=>nil, :average_scheduled_poll_interval=>15, :error_handlers=>[#<Sidekiq::ExceptionHandler::Logger:0x007fd9941704b0>], :lifecycle_events=>{:startup=>[], :quiet=>[], :shutdown=>[]}, :dead_max_jobs=>10000, :dead_timeout_in_seconds=>15552000, :verbose=>true, :strict=>true, :tag=>"app"}
2015-12-02T03:21:56.258884+00:00 app[worker.1]: 3 TID-owx1o19n8 INFO: Running in ruby 2.1.6p336 (2015-04-13 revision 50298) [x86_64-linux]
2015-12-02T03:21:56.258907+00:00 app[worker.1]: 3 TID-owx1o19n8 INFO: See LICENSE and the LGPL-3.0 for licensing details.
2015-12-02T03:21:56.258958+00:00 app[worker.1]: 3 TID-owx1o19n8 INFO: Upgrade to Sidekiq Pro for more features and support: http://sidekiq.org
2015-12-02T03:21:56.259223+00:00 app[worker.1]: 3 TID-owx1o19n8 DEBUG: Middleware: Sidekiq::Middleware::Server::Logging, Sidekiq::Middleware::Server::RetryJobs, Sidekiq::Middleware::Server::ActiveRecord, NewRelic::SidekiqInstrumentation
2015-12-02T03:21:56.259965+00:00 app[worker.1]: 3 TID-owx1o19n8 INFO: Starting processing, hit Ctrl-C to stop
2015-12-02T04:39:21.454835+00:00 heroku[worker.1]: State changed from up to down
2015-12-02T04:39:21.457769+00:00 heroku[worker.1]: State changed from down to starting
2015-12-02T04:39:26.668640+00:00 heroku[worker.1]: Starting process with command `bundle exec sidekiq -q default -q events -q summaries -c 5 -v`
2015-12-02T04:39:27.266199+00:00 heroku[worker.1]: State changed from starting to up
2015-12-02T04:39:33.394878+00:00 app[worker.1]: 3 TID-ovhui3tps INFO: See LICENSE and the LGPL-3.0 for licensing details.
2015-12-02T04:39:33.394849+00:00 app[worker.1]: 3 TID-ovhui3tps INFO: Running in ruby 2.1.6p336 (2015-04-13 revision 50298) [x86_64-linux]
2015-12-02T04:39:33.394880+00:00 app[worker.1]: 3 TID-ovhui3tps INFO: Upgrade to Sidekiq Pro for more features and support: http://sidekiq.org
2015-12-02T04:39:33.394911+00:00 app[worker.1]: 3 TID-ovhui3tps DEBUG: Middleware: Sidekiq::Middleware::Server::Logging, Sidekiq::Middleware::Server::RetryJobs, Sidekiq::Middleware::Server::ActiveRecord, NewRelic::SidekiqInstrumentation
2015-12-02T04:39:33.395068+00:00 app[worker.1]: 3 TID-ovhui3tps INFO: Booting Sidekiq 3.5.0 with redis options {:url=>"redis://redistogo:REDACTED@herring.redistogo.com:9015/"}
2015-12-02T04:39:33.395323+00:00 app[worker.1]: 3 TID-ovhui3tps INFO: Starting processing, hit Ctrl-C to stop
2015-12-02T04:39:33.397551+00:00 app[worker.1]: 3 TID-ovhvi71wo DEBUG: {:queues=>["default", "events", "summaries"], :labels=>[], :concurrency=>5, :require=>".", :environment=>nil, :timeout=>8, :poll_interval_average=>nil, :average_scheduled_poll_interval=>15, :error_handlers=>[#<Sidekiq::ExceptionHandler::Logger:0x007fa5ae5101e8>], :lifecycle_events=>{:startup=>[], :quiet=>[], :shutdown=>[]}, :dead_max_jobs=>10000, :dead_timeout_in_seconds=>15552000, :verbose=>true, :strict=>true, :tag=>"app"}
2015-12-02T17:20:37.438627+00:00 heroku[api]: Deploy 5b134d9 by grimm@grimmwerks.com
2015-12-02T17:20:37.438844+00:00 heroku[api]: Release v75 created by grimm@grimmwerks.com
2015-12-02T17:20:37.622940+00:00 heroku[slug-compiler]: Slug compilation started
2015-12-02T17:20:37.622950+00:00 heroku[slug-compiler]: Slug compilation finished
2015-12-02T17:20:37.544980+00:00 heroku[web.1]: State changed from crashed to starting
2015-12-02T17:20:37.591328+00:00 heroku[worker.1]: State changed from up to starting
2015-12-02T17:20:42.242042+00:00 heroku[worker.1]: Starting process with command `bundle exec sidekiq -q default -q events -q summaries -c 5 -v`
2015-12-02T17:20:42.943580+00:00 heroku[worker.1]: State changed from starting to up
2015-12-02T17:20:43.249474+00:00 heroku[worker.1]: Stopping all processes with SIGTERM
2015-12-02T17:20:43.251988+00:00 heroku[web.1]: Starting process with command `bundle exec thin start`
2015-12-02T17:20:44.908410+00:00 app[worker.1]: 3 TID-ovhui3tps INFO: Shutting down
2015-12-02T17:20:44.907780+00:00 app[worker.1]: 3 TID-ovhui3tps DEBUG: Got TERM signal
2015-12-02T17:20:45.116132+00:00 app[worker.1]: 3 TID-ovhvi71wo INFO: Terminating 5 quiet workers
2015-12-02T17:20:46.624432+00:00 heroku[worker.1]: Process exited with status 0
2015-12-02T17:20:54.410021+00:00 app[worker.1]: 3 TID-oswq49iqs INFO: Running in ruby 2.1.6p336 (2015-04-13 revision 50298) [x86_64-linux]
2015-12-02T17:20:54.410100+00:00 app[worker.1]: 3 TID-oswq49iqs INFO: See LICENSE and the LGPL-3.0 for licensing details.
2015-12-02T17:20:54.410133+00:00 app[worker.1]: 3 TID-oswq49iqs INFO: Upgrade to Sidekiq Pro for more features and support: http://sidekiq.org
2015-12-02T17:20:54.410239+00:00 app[worker.1]: 3 TID-oswq49iqs DEBUG: Middleware: Sidekiq::Middleware::Server::Logging, Sidekiq::Middleware::Server::RetryJobs, Sidekiq::Middleware::Server::ActiveRecord, NewRelic::SidekiqInstrumentation
2015-12-02T17:20:54.410481+00:00 app[worker.1]: 3 TID-oswq49iqs INFO: Booting Sidekiq 3.5.0 with redis options {:url=>"redis://redistogo:REDACTED@herring.redistogo.com:9015/"}
2015-12-02T17:20:54.410980+00:00 app[worker.1]: 3 TID-oswq49iqs INFO: Starting processing, hit Ctrl-C to stop
2015-12-02T17:20:54.413397+00:00 app[worker.1]: 3 TID-oswr2sii8 DEBUG: {:queues=>["default", "events", "summaries"], :labels=>[], :concurrency=>5, :require=>".", :environment=>nil, :timeout=>8, :poll_interval_average=>nil, :average_scheduled_poll_interval=>15, :error_handlers=>[#<Sidekiq::ExceptionHandler::Logger:0x007f4749e483a0>], :lifecycle_events=>{:startup=>[], :quiet=>[], :shutdown=>[]}, :dead_max_jobs=>10000, :dead_timeout_in_seconds=>15552000, :verbose=>true, :strict=>true, :tag=>"app"}
2015-12-02T17:20:57.846212+00:00 app[web.1]: Using rack adapter
2015-12-02T17:20:57.846235+00:00 app[web.1]: Thin web server (v1.6.4 codename Gob Bluth)
2015-12-02T17:20:57.846240+00:00 app[web.1]: Maximum connections set to 1024
2015-12-02T17:20:57.846259+00:00 app[web.1]: Listening on 0.0.0.0:3000, CTRL+C to stop
2015-12-02T17:21:43.725990+00:00 heroku[web.1]: Error R10 (Boot timeout) -> Web process failed to bind to $PORT within 60 seconds of launch
2015-12-02T17:21:43.725990+00:00 heroku[web.1]: Stopping process with SIGKILL
2015-12-02T17:21:44.726421+00:00 heroku[web.1]: State changed from starting to crashed
2015-12-02T17:21:44.727707+00:00 heroku[web.1]: State changed from crashed to starting
2015-12-02T17:21:44.708046+00:00 heroku[web.1]: Process exited with status 137
2015-12-02T17:21:50.866841+00:00 heroku[web.1]: Starting process with command `bundle exec thin start`
2015-12-02T17:21:58.836371+00:00 app[web.1]: Using rack adapter
2015-12-02T17:21:58.836406+00:00 app[web.1]: Thin web server (v1.6.4 codename Gob Bluth)
2015-12-02T17:21:58.836414+00:00 app[web.1]: Maximum connections set to 1024
2015-12-02T17:21:58.836414+00:00 app[web.1]: Listening on 0.0.0.0:3000, CTRL+C to stop
2015-12-02T17:22:51.214439+00:00 heroku[web.1]: Error R10 (Boot timeout) -> Web process failed to bind to $PORT within 60 seconds of launch
2015-12-02T17:22:51.214439+00:00 heroku[web.1]: Stopping process with SIGKILL
2015-12-02T17:22:52.253165+00:00 heroku[web.1]: State changed from starting to crashed
2015-12-02T17:22:52.238974+00:00 heroku[web.1]: Process exited with status 137
2015-12-02T17:54:24.126871+00:00 heroku[web.1]: State changed from crashed to starting
2015-12-02T17:54:29.023896+00:00 heroku[web.1]: Starting process with command `bundle exec thin start`
2015-12-02T17:54:37.430284+00:00 app[web.1]: Using rack adapter
2015-12-02T17:54:37.430307+00:00 app[web.1]: Thin web server (v1.6.4 codename Gob Bluth)
2015-12-02T17:54:37.430338+00:00 app[web.1]: Maximum connections set to 1024
2015-12-02T17:54:37.430367+00:00 app[web.1]: Listening on 0.0.0.0:3000, CTRL+C to stop
2015-12-02T17:55:29.042338+00:00 heroku[web.1]: Error R10 (Boot timeout) -> Web process failed to bind to $PORT within 60 seconds of launch
2015-12-02T17:55:29.042338+00:00 heroku[web.1]: Stopping process with SIGKILL
2015-12-02T17:55:30.089399+00:00 heroku[web.1]: Process exited with status 137
2015-12-02T17:55:30.110994+00:00 heroku[web.1]: State changed from starting to crashed
2015-12-02T18:12:50.842331+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=welldev.herokuapp.com request_id=5afa6e0c-fecd-46f0-9af6-c2e47407f8f0 fwd="208.46.240.4" dyno= connect= service= status=503 bytes=
2015-12-02T18:12:52.997877+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=welldev.herokuapp.com request_id=0baa0812-cd12-4c9d-a845-521bca7768ad fwd="208.46.240.4" dyno= connect= service= status=503 bytes=
2015-12-02T18:14:32.082068+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=welldev.herokuapp.com request_id=5a9ed7a8-a5b3-459e-9544-8bda096fe36a fwd="208.46.240.4" dyno= connect= service= status=503 bytes=

1 个答案:

答案 0 :(得分:0)

2015-12-02T17:20:57.846259+00:00 app[web.1]: Listening on 0.0.0.0:3000, CTRL+C to stop
2015-12-02T17:21:43.725990+00:00 heroku[web.1]: Error R10 (Boot timeout) -> Web process failed to bind to $PORT within 60 seconds of launch
2015-12-02T17:21:43.725990+00:00 heroku[web.1]: Stopping process with SIGKILL

显示问题 - 你绑定到端口3000而不是环境变量PORT,检查你的Procfile并确保你使用$ PORT,例如thin -p $PORT