The Prometheus, Alertmanager, Alerta, Pushgateway, and Grafana services are running in the Docker Swarm mode. This section describes how to restart these services.
To restart services running in Docker Swarm:
Log in to the Salt Master node.
Issue one of the following commands depending on the service you want to restart:
To restart Prometheus:
salt -C 'I@docker:swarm:role:master and I@prometheus:server' cmd.run \
"docker service update monitoring_server --force"
To restart Alertmanager:
salt -C 'I@docker:swarm:role:master and I@prometheus:server' cmd.run \
"docker service update monitoring_alertmanager --force"
To restart Alerta:
salt -C 'I@docker:swarm:role:master and I@prometheus:server' cmd.run \
"docker service update monitoring_alerta --force"
To restart Pushgateway:
salt -C 'I@docker:swarm:role:master and I@prometheus:server' cmd.run \
"docker service update monitoring_pushgateway --force"
To restart Grafana:
salt -C 'I@docker:swarm:role:master and I@prometheus:server' cmd.run \
"docker service update dashboard_grafana --force"
To restart Prometheus Relay:
salt -C 'I@docker:swarm:role:master and I@prometheus:server' cmd.run \
"docker service update monitoring_relay --force"
To restart Prometheus Remote Agent:
salt -C 'I@docker:swarm:role:master and I@prometheus:server' cmd.run \
"docker service update monitoring_remote_agent --force"