重启发现 worker 意外退出了
root@indiehackers:~/hd# sudo make status
Name Command State Ports
-------------------------------------------------------------------------------------------------------------------
homeland_app /home/app/homeland/bin/doc ... Up 0.0.0.0:7000->7000/tcp
homeland_app_backup bundle exec puma -C config ... Up 0.0.0.0:7001->7001/tcp
homeland_elasticsearch /docker-entrypoint.sh elas ... Up 0.0.0.0:32769->9200/tcp, 0.0.0.0:32768->9300/tcp
homeland_postgresql docker-entrypoint.sh postgres Up 0.0.0.0:5432->5432/tcp
homeland_redis docker-entrypoint.sh redis ... Up 0.0.0.0:6379->6379/tcp
homeland_web /etc/nginx/start Up 0.0.0.0:443->443/tcp, 0.0.0.0:80->80/tcp
homeland_worker bundle exec sidekiq -C con ... Exit 1
@huacnlee 问下这是啥原因?
sidekiq 最后一百行的日志:
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-5.2.7/lib/sidekiq.rb:97:in `block in redis'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/connection_pool-2.2.2/lib/connection_pool.rb:65:in `block (2 levels) in with'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/connection_pool-2.2.2/lib/connection_pool.rb:64:in `handle_interrupt'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/connection_pool-2.2.2/lib/connection_pool.rb:64:in `block in with'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/connection_pool-2.2.2/lib/connection_pool.rb:61:in `handle_interrupt'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/connection_pool-2.2.2/lib/connection_pool.rb:61:in `with'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-5.2.7/lib/sidekiq.rb:94:in `redis'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-scheduler-3.0.0/lib/sidekiq-scheduler/redis_manager.rb:121:in `clean_schedules_changed'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-scheduler-3.0.0/lib/sidekiq-scheduler.rb:14:in `block (2 levels) in <main>'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-5.2.7/lib/sidekiq/util.rb:57:in `block in fire_event'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-5.2.7/lib/sidekiq/util.rb:55:in `each'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-5.2.7/lib/sidekiq/util.rb:55:in `fire_event'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-5.2.7/lib/sidekiq/cli.rb:91:in `run'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-5.2.7/bin/sidekiq:12:in `<top (required)>'
/home/app/homeland/vendor/bundle/ruby/2.6.0/bin/sidekiq:23:in `load'
/home/app/homeland/vendor/bundle/ruby/2.6.0/bin/sidekiq:23:in `<top (required)>'
/usr/local/lib/ruby/2.6.0/bundler/cli/exec.rb:74:in `load'
/usr/local/lib/ruby/2.6.0/bundler/cli/exec.rb:74:in `kernel_load'
/usr/local/lib/ruby/2.6.0/bundler/cli/exec.rb:28:in `run'
/usr/local/lib/ruby/2.6.0/bundler/cli.rb:463:in `exec'
/usr/local/lib/ruby/2.6.0/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
/usr/local/lib/ruby/2.6.0/bundler/vendor/thor/lib/thor/invocation.rb:126:in `invoke_command'
/usr/local/lib/ruby/2.6.0/bundler/vendor/thor/lib/thor.rb:387:in `dispatch'
/usr/local/lib/ruby/2.6.0/bundler/cli.rb:27:in `dispatch'
/usr/local/lib/ruby/2.6.0/bundler/vendor/thor/lib/thor/base.rb:466:in `start'
/usr/local/lib/ruby/2.6.0/bundler/cli.rb:18:in `start'
/usr/local/lib/ruby/gems/2.6.0/gems/bundler-1.17.2/exe/bundle:30:in `block in <top (required)>'
/usr/local/lib/ruby/2.6.0/bundler/friendly_errors.rb:124:in `with_friendly_errors'
/usr/local/lib/ruby/gems/2.6.0/gems/bundler-1.17.2/exe/bundle:22:in `<top (required)>'
/usr/local/bundle/bin/bundle:23:in `load'
/usr/local/bundle/bin/bundle:23:in `<main>'
2019-11-20T12:10:50.514Z 1 TID-14v7x4vp INFO: Booting Sidekiq 5.2.7 with redis options {:namespace=>"sidekiq", :url=>"redis://redis:6379/1", :driver=>:hiredis, :db=>0, :id=>"Sidekiq-server-PID-1"}
2019-11-20T12:10:51.808Z 1 TID-14v7x4vp INFO: Running in ruby 2.6.3p62 (2019-04-16 revision 67580) [x86_64-linux-musl]
2019-11-20T12:10:51.808Z 1 TID-14v7x4vp INFO: See LICENSE and the LGPL-3.0 for licensing details.
2019-11-20T12:10:51.808Z 1 TID-14v7x4vp INFO: Upgrade to Sidekiq Pro for more features and support: http://sidekiq.org
2019-11-20T12:10:51.809Z 1 TID-14v7x4vp WARN: Sidekiq 6.0 will require Redis 4.0+, you are using Redis v3.2.7
2019-11-20T12:10:51.810Z 1 TID-14v7x4vp WARN: {"context":"Exception during Sidekiq lifecycle event.","event":"startup"}
2019-11-20T12:10:51.810Z 1 TID-14v7x4vp WARN: Redis::CommandError: MISCONF Redis is configured to save RDB snapshots, but is currently not able to persist on disk. Commands that may modify the data set are disabled. Please check Redis logs for details about the error.
2019-11-20T12:10:51.810Z 1 TID-14v7x4vp WARN: /home/app/homeland/vendor/bundle/ruby/2.6.0/gems/redis-4.1.2/lib/redis/client.rb:126:in `call'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/redis-4.1.2/lib/redis.rb:538:in `block in del'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/redis-4.1.2/lib/redis.rb:52:in `block in synchronize'
/usr/local/lib/ruby/2.6.0/monitor.rb:230:in `mon_synchronize'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/redis-4.1.2/lib/redis.rb:52:in `synchronize'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/redis-4.1.2/lib/redis.rb:537:in `del'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/redis-namespace-1.6.0/lib/redis/namespace.rb:442:in `call_with_namespace'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/redis-namespace-1.6.0/lib/redis/namespace.rb:328:in `method_missing'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-scheduler-3.0.0/lib/sidekiq-scheduler/redis_manager.rb:121:in `block in clean_schedules_changed'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-5.2.7/lib/sidekiq.rb:97:in `block in redis'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/connection_pool-2.2.2/lib/connection_pool.rb:65:in `block (2 levels) in with'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/connection_pool-2.2.2/lib/connection_pool.rb:64:in `handle_interrupt'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/connection_pool-2.2.2/lib/connection_pool.rb:64:in `block in with'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/connection_pool-2.2.2/lib/connection_pool.rb:61:in `handle_interrupt'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/connection_pool-2.2.2/lib/connection_pool.rb:61:in `with'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-5.2.7/lib/sidekiq.rb:94:in `redis'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-scheduler-3.0.0/lib/sidekiq-scheduler/redis_manager.rb:121:in `clean_schedules_changed'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-scheduler-3.0.0/lib/sidekiq-scheduler.rb:14:in `block (2 levels) in <main>'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-5.2.7/lib/sidekiq/util.rb:57:in `block in fire_event'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-5.2.7/lib/sidekiq/util.rb:55:in `each'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-5.2.7/lib/sidekiq/util.rb:55:in `fire_event'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-5.2.7/lib/sidekiq/cli.rb:91:in `run'
/home/app/homeland/vendor/bundle/ruby/2.6.0/gems/sidekiq-5.2.7/bin/sidekiq:12:in `<top (required)>'
/home/app/homeland/vendor/bundle/ruby/2.6.0/bin/sidekiq:23:in `load'
/home/app/homeland/vendor/bundle/ruby/2.6.0/bin/sidekiq:23:in `<top (required)>'
/usr/local/lib/ruby/2.6.0/bundler/cli/exec.rb:74:in `load'
/usr/local/lib/ruby/2.6.0/bundler/cli/exec.rb:74:in `kernel_load'
/usr/local/lib/ruby/2.6.0/bundler/cli/exec.rb:28:in `run'
/usr/local/lib/ruby/2.6.0/bundler/cli.rb:463:in `exec'
/usr/local/lib/ruby/2.6.0/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
/usr/local/lib/ruby/2.6.0/bundler/vendor/thor/lib/thor/invocation.rb:126:in `invoke_command'
/usr/local/lib/ruby/2.6.0/bundler/vendor/thor/lib/thor.rb:387:in `dispatch'
/usr/local/lib/ruby/2.6.0/bundler/cli.rb:27:in `dispatch'
/usr/local/lib/ruby/2.6.0/bundler/vendor/thor/lib/thor/base.rb:466:in `start'
/usr/local/lib/ruby/2.6.0/bundler/cli.rb:18:in `start'
/usr/local/lib/ruby/gems/2.6.0/gems/bundler-1.17.2/exe/bundle:30:in `block in <top (required)>'
/usr/local/lib/ruby/2.6.0/bundler/friendly_errors.rb:124:in `with_friendly_errors'
/usr/local/lib/ruby/gems/2.6.0/gems/bundler-1.17.2/exe/bundle:22:in `<top (required)>'
/usr/local/bundle/bin/bundle:23:in `load'
/usr/local/bundle/bin/bundle:23:in `<main>'