naichi's lab

3日後の自分(他人)への書き置き

unicornの起動と終了

環境

  • CentOS Linux release 7.1.1503 (Core)
  • unicorn v5.0.1

Unicorn起動

Railsフォルダで

$ bundle exec unicorn_rails -c config/unicorn.rb -E production -D

Unicorn起動確認

$ ps -ef | grep unicorn
unityro+  8575     1  0 17:18 ?        00:00:01 unicorn_rails master -c config/unicorn.rb -E production -D
unityro+  8579  8575  0 17:18 ?        00:00:00 unicorn_rails worker[0] -c config/unicorn.rb -E production -D
unityro+  8582  8575  0 17:18 ?        00:00:00 unicorn_rails worker[1] -c config/unicorn.rb -E production -D
unityro+  8585  8575  0 17:18 ?        00:00:00 unicorn_rails worker[2] -c config/unicorn.rb -E production -D
unityro+  8648  6240  0 17:28 pts/6    00:00:00 grep --color=auto unicorn

終了

$ kill -QUIT [PID]