Linux 程序和 systemd 服務監視
Scollector 將監視配置檔案中指定的 Linux 程序 。
[[Process]]
Command = "/opt/bosun/bosun"
Name = "bosun"
[[Process]]
Command = "ruby"
Name = "puppet-agent"
Args = "puppet"
[[Process]]
Command = "/haproxy$"
Name = "haproxy-t1"
Args = "/etc/haproxy-t1/haproxy-t1.cfg"
[[Process]]
Command = '/usr/bin/redis-server \*:16389'
Name = "redis-bosun-dev"
IncludeCount = true
Scollector 還可以使用 D-Bus API 來確定 systemd 管理並在配置檔案中指定的服務狀態。
[[SystemdService]]
Name = "^(puppet|redis-.*|keepalived|haproxy-t.*)$"
WatchProc = false
[[SystemdService]]
Name = "^(scollector|memcached)$"
WatchProc = true