+++ title = "Server Services" draft = false
gh_repo = "chef-server"
aliases = ["/server_services.html", "/runbook/server_services/"]
[menu] [menu.server] title = "Services" identifier = "server/overview/Services" parent = "server/overview" weight = 60 +++
The Chef Infra Server has a built in process supervisor, which ensures that all of the required services are in the appropriate state at any given time. The supervisor starts two processes per service.
{{< readfile file="content/server/reusable/md/ctl_common_service_subcommands.md" >}}
{{< readfile file="content/server/reusable/md/ctl_chef_server_hup.md" >}}
{{< readfile file="content/server/reusable/md/ctl_chef_server_int.md" >}}
{{< readfile file="content/server/reusable/md/ctl_chef_server_kill.md" >}}
{{< readfile file="content/server/reusable/md/ctl_chef_server_once.md" >}}
{{< readfile file="content/server/reusable/md/ctl_chef_server_restart.md" >}}
{{< readfile file="content/server/reusable/md/ctl_chef_server_service_list.md" >}}
{{< readfile file="content/server/reusable/md/ctl_chef_server_start.md" >}}
{{< readfile file="content/server/reusable/md/ctl_chef_server_status.md" >}}
{{< readfile file="content/server/reusable/md/ctl_chef_server_status_logs.md" >}}
{{< readfile file="content/server/reusable/md/ctl_chef_server_stop.md" >}}
{{< readfile file="content/server/reusable/md/ctl_chef_server_tail.md" >}}
{{< readfile file="content/server/reusable/md/ctl_chef_server_term.md" >}}
The following services are part of the Chef Infra Server:
- bifrost
- bookshelf
- elasticsearch
- nginx
- opscode-erchef
- postgresql
- redis-lb
{{< readfile file="content/server/reusable/md/server_services_bifrost.md" >}}
To view the status for the service:
chef-server-ctl status bifrost
to return something like:
run: bifrost: (pid 1234) 123456s; run: log: (pid 5678) 789012s
To start the service:
chef-server-ctl start bifrost
To stop the service:
chef-server-ctl stop bifrost
To restart the service:
chef-server-ctl restart bifrost
to return something like:
ok: run: bifrost: (pid 1234) 1234s
To kill the service (send a SIGKILL
command):
chef-server-ctl kill bifrost
To run the service, but not restart it (if the service fails):
chef-server-ctl once bifrost
To follow the logs for the service:
chef-server-ctl tail bifrost
{{< readfile file="content/server/reusable/md/server_services_bookshelf.md" >}}
To view the status for the service:
chef-server-ctl status bookshelf
to return something like:
run: bookshelf: (pid 1234) 123456s; run: log: (pid 5678) 789012s
To start the service:
chef-server-ctl start bookshelf
To stop the service:
chef-server-ctl stop bookshelf
To restart the service:
chef-server-ctl restart bookshelf
to return something like:
ok: run: bookshelf: (pid 1234) 1234s
To kill the service (send a SIGKILL
command):
chef-server-ctl kill bookshelf
To run the service, but not restart it (if the service fails):
chef-server-ctl once bookshelf
To follow the logs for the service:
chef-server-ctl tail bookshelf
To view the status for the service:
chef-server-ctl status elasticsearch
to return something like:
elasticsearch: (pid 12345) 1s; run: log: (pid 5678) 123456s
To start the service:
chef-server-ctl start elasticsearch
to return something like:
ok: run: elasticsearch: (pid 5678) 0s
To stop the service:
chef-server-ctl stop elasticsearch
to return something like:
ok: down: elasticsearch: 123456s, normally up
To restart the service:
chef-server-ctl restart elasticsearch
to return something like:
ok: run: elasticsearch: (pid 56789) 1s
To kill the service (send a SIGKILL
command):
chef-server-ctl kill elasticsearch
chef-server-ctl once elasticsearch
To follow the logs for the service:
chef-server-ctl tail elasticsearch
{{< readfile file="content/server/reusable/md/server_services_nginx.md" >}}
To view the status for the service:
chef-server-ctl status nginx
to return something like:
run: nginx: (pid 1234) 123456s; run: log: (pid 5678) 789012s
To start the service:
chef-server-ctl start nginx
To stop the service:
chef-server-ctl stop nginx
To restart the service:
chef-server-ctl restart nginx
to return something like:
ok: run: nginx: (pid 1234) 1234s
To kill the service (send a SIGKILL
command):
chef-server-ctl kill nginx
To run the service, but not restart it (if the service fails):
chef-server-ctl once nginx
{{< readfile file="content/server/reusable/md/server_services_nginx_tail.md" >}}
{{< readfile file="content/server/reusable/md/server_services_erchef.md" >}}
To view the status for the service:
chef-server-ctl status opscode-erchef
to return something like:
run: opscode-erchefs: (pid 1234) 123456s; run: log: (pid 5678) 789012s
To start the service:
chef-server-ctl start opscode-erchef
To stop the service:
chef-server-ctl stop opscode-erchef
To restart the service:
chef-server-ctl restart opscode-erchef
to return something like:
ok: run: opscode-erchef: (pid 1234) 1234s
To kill the service (send a SIGKILL
command):
chef-server-ctl kill opscode-erchef
To run the service, but not restart it (if the service fails):
chef-server-ctl once opscode-erchef
To follow the logs for the service:
chef-server-ctl tail opscode-erchef
{{< readfile file="content/server/reusable/md/server_services_postgresql.md" >}}
To view the status for the service:
chef-server-ctl status postgresql
to return something like:
run: postgresql: (pid 1234) 123456s; run: log: (pid 5678) 789012s
To start the service:
chef-server-ctl start postgresql
To stop the service:
chef-server-ctl stop postgresql
To restart the service:
chef-server-ctl restart postgresql
to return something like:
ok: run: postgresql: (pid 1234) 1234s
To kill the service (send a SIGKILL
command):
chef-server-ctl kill postgresql
To run the service, but not restart it (if the service fails):
chef-server-ctl once postgresqls
To follow the logs for the service:
chef-server-ctl tail postgresql
{{< readfile file="content/server/reusable/md/server_services_redis.md" >}}
To view the status for the service:
chef-server-ctl status redis
to return something like:
run: redis: (pid 1234) 123456s; run: log: (pid 5678) 789012s
To start the service:
chef-server-ctl start redis
To stop the service:
chef-server-ctl stop redis
To restart the service:
chef-server-ctl restart redis
to return something like:
ok: run: redis: (pid 1234) 1234s
To kill the service (send a SIGKILL
command):
chef-server-ctl kill name_of_service
To run the service, but not restart it (if the service fails):
chef-server-ctl once redis
To follow the logs for the service:
chef-server-ctl tail name_of_service