Sensu comes in two pieces: then Sensu-Backend und the Sensu-Agent. The communication is made encrypted via websockets.
While the Sensu-Backend represents the server component, the Sensu-Agent is installed on the systems to be monitored.
Etcd instances built into the Sensu-Backend are used to store configuration and live data. Etcd, which is also used by Kubernetes, is a distributed NoSQL key-value store and uses Raft (https://raft.github.io/), a “consensus algorithm”. If Sensu is to be used as a cluster with multiple instances, the data will automatically replicate by adding more Sensu-Backend instances.
On the other hand, the Sensu-Agent automatically register at the Sensu-Backend or Sensu-Backend-Cluster, perform the monitoring checks that are intended for them and continously send keepalive messages. The publish-subscribe approach to trigger montioring checks can save a lot of cpu time compared to traditional monitoring solutions. The Sensu-Agents are assigned to subscriptions, which also can be understood as tags. On the other hand, the monitoring checks (eg. CPU, memory, disks, processes, etc.) also are categorized by means of subscriptions. If a check request is triggered and has, for example, the subscription “webserver”, all Sensu-Agents with the subscription “webserver” perform this check.
Sensu unfolds it strengts in highly dynamic cloud and cloud-like environments where the fluctuation of hard- or software is high.
With the help of automation tools such as Ansible, Check, Puppet and SaltStack, the monitoring content of Sensu can automatically be adapted to the changes in the IT landscape in real time, without an administrator having to maintain it manually.
You can find additional information about Sensu on the developer’s website www.sensu.io