www.icinga.org
OpenNebulaConf – 2016
ICINGA 2 – APIFY THEM ALL
• Achim Ledermüller
• Lead Senior Systems Engineer
• DC automation
• @netways since 2012
Quick Poll
Open Source Monitoring
Icinga is a scalable and extensible monitoring
system which checks the availability of your
resources, notifies users of outages and provides
extensive BI data.
CheckerChecker
NotifyNotify
GelfGelf
PerfdataPerfdata GraphiteGraphite
IDOIDO
CompatCompat
Livestatu
s
Livestatu
s
• distributed &
high-available
• zone support
• modular features
• user-friendly
configuration
ICINGA2 - API
• HTTP with RESTful Url Schema
• ApiUser config object
• X.509 and/or Basic Auth
• create, modify and delete objects
• retrieve information and run actions
• subscribe to events
VM_HOOK = [
name = "create_icinga2_host",
on = "CREATE",
command = "/usr/local/bin/createHost.sh",
arguments = "$ID $TEMPLATE" ]
VM_HOOK = [
name = "delete_icinga2_host",
on = "DONE",
command = "/usr/local/bin/deleteHost.sh",
arguments = "$ID $TEMPLATE" ]
# cat createHost.sh
curl -s -u 'root:icinga'
-H 'Accept: application/json'
-X PUT
"https://icinga2:5665/v1/objects/hosts/$1"
-d '{
"templates": [ "generic-host" ],
"attrs": {
"address": "8.8.8.8",
"vars.os" : "Linux",
"vars.hostgroups": “myhg"
}
}'
tiny demo
• API and hooks enable an easy
integration
• play with the Icinga2 Vagrant boxes
and ONE Sandbox to get in touch
Thank you!
www.icinga.org
dev.icinga.org
git.icinga.org
@icinga
/icinga
+icinga

OpenNebulaConf 2016 - Icinga2 - APIFY them all by Achim Ledermüller, Netways GmbH