stiziwik
Sie befinden sich hier: Willkommen » linux » Icinga » Konfigurationsbeispiele
Zuletzt angesehen: • Konfigurationsbeispiele

Konfigurationsbeispiele

Hier einige Beispiele.

Hosts

object Host NodeName {
  import "generic-host"
  address = "127.0.0.1"
  address6 = "::1"
  vars.os = "Linux"
  vars.http_vhosts["http"] = {
    http_uri = "/"
  }
  //vars.http_vhosts["Icinga Web 2"] = {
  //  http_uri = "/icingaweb2"
  //}

  vars.disks["disk"] = {
    /* No parameters. */
  }
  vars.disks["disk /"] = {
    disk_partitions = "/"
  }

  vars.notification["mail"] = {
    /* The UserGroup `icingaadmins` is defined in `users.conf`. */
    groups = [ "icingaadmins" ]
  }

  vars.mysql_username="<USERNAME>"
  vars.mysql_password="yPASSWORD>"

}

Services

apply Service "dovecot-imaps" {
  import "generic-service"
  check_command = "tcp"
  vars.tcp_port="993"
  assign where host.name == NodeName
}

apply Service "amavisd-new" {
  import "generic-service"
  check_command = "tcp"
  vars.tcp_port="10026"
  assign where host.name == NodeName
}

apply Service "amavis-milter" {
  import "generic-service"
  check_command = "tcp"
  vars.tcp_port="60001"
  assign where host.name == NodeName
}

apply Service "postfix" {
  import "generic-service"
  check_command = "tcp"
  vars.tcp_port="25"
  assign where host.name == NodeName
}

apply Service "policyd-weight" {
  import "generic-service"
  check_command = "tcp"
  vars.tcp_port="12525"
  assign where host.name == NodeName
}

apply Service "nginx-https" {
  import "generic-service"
  check_command = "http"
  vars.http_ssl="true"
  assign where host.name == NodeName
}

apply Service "mysql-server" {
  import "generic-service"
  check_command = "mysql"
  assign where host.name == NodeName
}

Users

object User "<USERNAME>" {
  import "generic-user"
  display_name = "<DISPLAYNAME>"
  groups = [ "<GROUPNAME>" ]

  email = "<MAILADRESS>"
}

object UserGroup "icingaadmins" {
  display_name = "Icinga 2 Admin Group"
}

Templates

template Host "generic-host" {
  max_check_attempts = 3
  check_interval = 1m
  retry_interval = 30s

  check_command = "hostalive"

  vars.notification_from="<MAILADRESS>"
}

template Service "generic-service" {
  max_check_attempts = 5
  check_interval = 1m
  retry_interval = 30s

  vars.notification_from="<MAILADRESS>"

}

template User "generic-user" {

}

template Notification "mail-host-notification" {
  command = "mail-host-notification"

  states = [ Up, Down ]
  types = [ Problem, Acknowledgement, Recovery, Custom,
            FlappingStart, FlappingEnd,
            DowntimeStart, DowntimeEnd, DowntimeRemoved ]

  vars += {
    // notification_icingaweb2url = "https://www.example.com/icingaweb2"
    // notification_from = "Icinga 2 Host Monitoring <icinga@example.com>"
    notification_logtosyslog = false
  }

  period = "24x7"
}

template Notification "mail-service-notification" {
  command = "mail-service-notification"

  states = [ OK, Warning, Critical, Unknown ]
  types = [ Problem, Acknowledgement, Recovery, Custom,
            FlappingStart, FlappingEnd,
            DowntimeStart, DowntimeEnd, DowntimeRemoved ]

  vars += {
    // notification_icingaweb2url = "https://www.example.com/icingaweb2"
    // notification_from = "Icinga 2 Service Monitoring <icinga@example.com>"
    notification_logtosyslog = false
  }

  period = "24x7"
}
Previous Next

Webseiten-Werkzeuge

  • Letzte Änderungen
  • Medien-Manager
  • Übersicht

Seiten-Werkzeuge

  • Zeige Quelltext
  • Ältere Versionen
  • Links hierher
  • Nach oben

Benutzer-Werkzeuge

  • Anmelden
linux/icinga/konfigurationsbeispiele.txt · Zuletzt geändert: 2019/11/26 14:11 von 127.0.0.1
stiziwik

Table of Contents

Inhaltsverzeichnis

  • Konfigurationsbeispiele
    • Hosts
    • Services
    • Users
    • Templates
  • Android
  • Bild-und-video
  • Datenverarbeitung
  • Fahrzeuge
  • Hausautomatisation
  • linux
    • Alix-router
    • Icinga
      • Docker Compose Icinga stack
      • Installation-full
      • Installation-Quick
      • Konfigurationsbeispiele
    • Log-Server
    • Mail
    • Mysql
    • Nagios
    • Owncloud
    • Virtualisierung
    • Webcam
    • Accl Attr
    • Alternativen-System
    • Antivirus-live
    • Anzahl
    • Audacious
    • Audiodateien-umwandeln
    • Avira-Live-Rescue
    • Backupscript
    • Bash
    • Beep-mit-Ringtones
    • Benutzerpassword Deaktivieren
    • Bluetooth
    • Bootvorgang
    • CD-Ripper
    • Clonezilla
    • Coredump
    • Datenrettung
    • Datum Und Uhrzeit
    • dd
    • Desktop-dateien
    • Docker
    • Duplikate
    • Fail2ban
    • Festplatten
    • Fingerprintsensor
    • Gddrescue
    • Geda
    • Genisoimage mkisofs
    • Grub
    • Internetradio
    • Ipod
    • Journalctl
    • Keepass
    • Kernel Bauen
    • Keystore
    • Live-CD erstellen
    • Lnav
    • Lshw-hardware
    • Message-of-the-day
    • Midnight Commander
    • Mongodb
    • Nohup, Hintergrund, anhalten und Co
    • Openssl
    • Pakete bauen
    • Paketverwaltung
    • Passwort-Generator
    • Patches
    • Prüfsumme
    • Quota
    • Remote Desktop Verbindung
    • Request Tracker
    • Rsync
    • Samba
    • Scriptschnipsel
    • Serielle-Konsole
    • Smartmontools
    • Sms-gateway
    • Softwareraid
    • Squid
    • SSH
    • Stats
    • Stresstest
    • Strongswan VPN
    • Sudo
    • Supergrub2disk
    • Supervisord
    • Swap
    • Syslog
    • Systemrescue
    • Tftp
    • Thunderbird
    • Umbenennen
    • Unity Fenstermanager
    • Video-streaming
    • Virenscan-script
    • Virtualbox
    • Virtualisierung
    • Vnc-vino
    • Watchdog
    • Webmin
    • Wmctrl
    • Zeitsynchronisation Mit DCF-77 Empfänger
    • Zoneminder
  • Nas
  • Netzwerk
  • PlayGround
  • Programieren
  • Projekte
  • Raspberry Pi
  • sonstiges
  • VDR
  • Web
  • Werkstatt
  • Wiki
  • sidebar-acmenu
  • sidebar-indexmenu
  • sidebar-simplenavi