TechDocs/TechnicalProcesses/Monitoring/AddNewServer

Add a new server

Please note that for now only debian servers are supported. To add a new server to the icinga monitoring system, follow these steps:

Add the server in the Ansible playbook

Clone the repository and put the server address in the icinga2_clients section of thehosts file. This will:

Add the server in the icinga configuration

Add the server in the conf.d/hosts.conf file. Here is an example:

object Host "host1" {
  import "ssh-agent"

  address = "host1.example.org"
  address6 = "host1.example.org"

  # Ensure apache2 is running
  vars.service["apache2"] = {
    service_to_check = "apache2"
  }
  
  # Check disk space
  vars.disks["/"] = {
    disk_partition = "/"
  }

  # Check website
  vars.http_vhosts["examplepage"] = {
    http_uri = "/"
    http_vhost = "url.example.org"
    http_ssl = true
  }
}

Please see the file conf.d/commands.conf for a list of already existing monitoring commands meant to be used via SSH. Please follow the steps in the page ../AddNewPlugin, for details about how to create new ones.

Deploy

To deploy the changed configuration, add your changes to the git repository and run the ansible playbook by following the intructions in the README.

TechDocs/TechnicalProcesses/Monitoring/AddNewServer (last edited 2020-06-19 10:54:53 by max.mehl)