SlideShare ist ein Scribd-Unternehmen logo
1 von 33
Downloaden Sie, um offline zu lesen
Automatische Konfiguration von Nagios/Icinga
mit Agordamon
Christian Schneemann
http://www.b1-systems.de
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agenda
Wege Nagios/Icinga zu konfigurieren
Agordamon
Warum ein weiteres Tool...
Was kann es...
Wofür ist es gedacht..
Wie funktioniert es...
Beispiele aus der Praxis
Agordamon mit Nmap
Agordamon mit CMDB
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Wege Nagios/Icinga zu konfigurieren
Wege Nagios/Icinga zu
konfigurieren
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Wege Nagios/Icinga zu konfigurieren
Konfigurationstools
NagiosQL
NConf
LConf
. . .
$EDITOR
Tools um Konfigurationen automatisch zu erstellen:
u. a. Agordamon
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon
Agordamon
http://github.com/cschneemann/agordamon
[EO] agordaro ([EDV] (z.B. in Konfigurationsdateien oder der Registry) Konfigurationseinstellungen) + mon
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Warum?
viele Tools verfügbar..
Webapplikationen
Datenbankgestützt
einfach benutztbar..
. . . aber . . .
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Warum?
es fehlte etwas . . .
Datenquellen anzapfen (CMDB, Listen, . . . )
einfach scriptbar
perlbasiert
flexibel
. . .
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Warum?
also
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Was kann es?
Unterstützt bei der Erstellung von Nagios/Icinga
Konfigurationsobjekten
vorhandene Konfigurationen können eingelesen werden
Objekte können in einer MongoDB zwischengespeichert werden
keine vollständigen Konfigurationen nötig -> Mischbetrieb
möglich
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Wo setzt man es ein?
zur initialen "Befüllung"mit anschließender manueller
Überarbeitung
in homogene Umgebungen, z.B. Webserverfarm, SAN
Umgebungen
in "Clouds", gekoppelt mit Provisionierungsscripten
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Wo wird es eingesetzt
Agordamon wird seit 2010 bei Kunden eingesetzt für. . .
. . . automatische, regelbasierte Konfigurationserstellung aller
Server Server der Abteilung:
sortierung in Gruppen nach Teamzugehörigkeit/Kostenstelle
Überwachen von definierten Standards
Abgleich der Kontaktdaten/Gruppenzugehörigkeit gegen
Adressbücher
Zuordnung von Verantwortlichkeiten mit Listen
contact Erstellung bei Neueinstellungen (Änderung im
Adressbuch)
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Wie nutzt man es?
... Arten zur Konfigurationserstellung:
"write only": komplette Objektkonfiguration wird (teilweise) neu
erstellt
datenbankgestützt: Objekte werden in der Datenbank erstellt
oder verändert
gemischt: ein Teil wird neu generiert, ein Teil aus
Datenbank/alten Konfigurationen
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Wie funktioniert es?
Perl Modul
unabhängige Objekte
keine direkten Abhängigkeiten, keine Baumstruktur
”Abhängigkeiten” durch Queries
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Befehlsübersicht
create_object($type, %definition)
delete_object($type, $query)
create_config(@types)
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Befehlsübersicht
create_object($type, %definition)
create_object("service", name => "hostname,ssh",
service_description => "SSH",
host_name => "testhost23",
use => "check_ssh",
check_command => "check_ssh",
register => "1");
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Befehlsübersicht
delete_object($type, $query)
delete_object("hosts", { host_name => "testhost05"} );
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Befehlsübersicht
create_config(@types)
create_config("host", "service");
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Befehlsübersicht
Befehle für Gruppen:
add_member2group($type, $group, $member)
add_group2member($type, $host, $group)
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Beispiel
Innerhalb von Perl-Scripten:
#!/usr/bin/perl
use agordamon;
my $an = agordamon->new(db_type => "files");
$an->create_object("host", host_name => "xen01",
address => "10.10.0.23",
use => "xen_hosts",
register => "1" );
$an->create_object("service", name => "xen01,ssh",
service_description => "SSH",
host_name => "xen01",
check_command => "check_ssh",
use => "check_ssh",
register => "1");
print $an->create_config("host", "service");
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Installation
per RPM (openSUSE 11.4, 12.1, 12.2, Factory, Tumbleweed,
weitere !SUSE folgen...)
http://download.opensuse.org/repositories/home:/cschneemann/
$ tar xfzv agordamon-0.23.5.tar.gz
$ perl Makefile.PL
$ make
# make install
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon mit nmap
Agordamon mit nmap
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - in Zusammenspiel mit nmap
1 Netzwerk scannen mit nmap
Daten aufbereiten per snmp scan
2 Agordamonscript erstellen zum Auswerten
3 Konfiguration erstellen lassen
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - in Zusammenspiel mit nmap
# nmap -O --osscan-guess -sS -F -sV -oX nmap2.xml 
> 192.168.178.0-255
-F fast mode
-sV probe version
-sS SYN
-O OS detection
-oX output XML
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - in Zusammenspiel mit nmap
#!/usr/bin/perl
use Nmap::Parser;
use agordamon;
my $an = agordamon->new(db_type => "files");
my $np = new Nmap::Parser;
$np->parsefile($nmap_file);
for my $host ($np->all_hosts()) {
my $anhost = $an->create_object("host", host_name => $host->hostname(),
address => $host->addr(),
use => $hosts_template,
register => "1" );
for my $port (@tcp_ports) {
if ( $svc->name eq "ssh" ) {
$an->create_object("service", name => $hostname.",ssh",
service_description => "SSH",
host_name => $host->hostname(),
use => "check_ssh",
check_command => "check_ssh",
register => "1");
}
}
}
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - in Zusammenspiel mit inmap
DEMO
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon mit CMDB
Agordamon mit CMDB
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - in Zusammenspiel mit CMDB
1 Export generieren
2 Agordamonscript erstellen zum Auswerten
3 Konfiguration erstellen lassen
Script kann regelmäßig laufen
Nagios/Icinga immer auf dem aktuellsten Stand
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - in Zusammenspiel mit CMDB
DEMO
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - in Zusammenspiel mit CMDB
Was kann man also mit Agordamon erreichen...
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - Einsatzmöglichkeiten
Nagios/Icinga. . .
. . . ’grob” vorbefüllen
. . . synchron mit Datenquellen halten
contacts <-> Adressbuch
hosts <-> CMDB
hostgruppen <-> Teams <-> CMDB/Adressbuch
. . .
. . .
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Agordamon - die Zukunft..
intern aufräumen
Code säubern
FIXMEs und TODOs bearbeiten
weitere Datenbanken unterstützen
Objektverwaltung anderer Module nutzen (Nagios::Config)
einfacher nutzbar machen
mehr Beispielscripte/fertige Tools
Dokumentation++
. . .
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
Fragen
Fragen?
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
vielen Dank für die Aufmerksamkeit
. . . doch noch Fragen?
schneemann@b1-systems.de
c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012

Weitere ähnliche Inhalte

Ähnlich wie OSMC 2012 | Automatische Konfiguration von Nagios/Icinga mit Agordamon by Christian Schneemann

Monitoring von SAP mit check_sap_health
Monitoring von SAP mit check_sap_healthMonitoring von SAP mit check_sap_health
Monitoring von SAP mit check_sap_healthGerhard Lausser
 
Some Bashing II - Mit der Kommandozeile Abläufe automatisieren
Some Bashing II - Mit der Kommandozeile Abläufe automatisierenSome Bashing II - Mit der Kommandozeile Abläufe automatisieren
Some Bashing II - Mit der Kommandozeile Abläufe automatisierenB1 Systems GmbH
 
System- & Konfigurationsmanagement mit Foreman & Puppet
System- & Konfigurationsmanagement mit Foreman & Puppet System- & Konfigurationsmanagement mit Foreman & Puppet
System- & Konfigurationsmanagement mit Foreman & Puppet B1 Systems GmbH
 
Systemmanagement mit Puppet und Foreman
Systemmanagement mit Puppet und ForemanSystemmanagement mit Puppet und Foreman
Systemmanagement mit Puppet und ForemanB1 Systems GmbH
 
ADR Best Practices - DOAG Regio-Treffen 2010 - OPITZ CONSULTING - Christian B...
ADR Best Practices - DOAG Regio-Treffen 2010 - OPITZ CONSULTING - Christian B...ADR Best Practices - DOAG Regio-Treffen 2010 - OPITZ CONSULTING - Christian B...
ADR Best Practices - DOAG Regio-Treffen 2010 - OPITZ CONSULTING - Christian B...OPITZ CONSULTING Deutschland
 
AdminCamp 2011 Performance
AdminCamp 2011 PerformanceAdminCamp 2011 Performance
AdminCamp 2011 PerformanceUlrich Krause
 
Migrate your Sametime Server to LDAP Authentication (Admincamp 2013)
Migrate your Sametime Server to LDAP Authentication (Admincamp 2013)Migrate your Sametime Server to LDAP Authentication (Admincamp 2013)
Migrate your Sametime Server to LDAP Authentication (Admincamp 2013)Novakenstein
 
B1 Acocon Lotus Day 08.09.2009
B1 Acocon Lotus Day 08.09.2009B1 Acocon Lotus Day 08.09.2009
B1 Acocon Lotus Day 08.09.2009Andreas Schulte
 
CodeTalks Vortrag: Automatisierung mit Ansible & Jenkins @ LeanIX Enterprise ...
CodeTalks Vortrag: Automatisierung mit Ansible & Jenkins @ LeanIX Enterprise ...CodeTalks Vortrag: Automatisierung mit Ansible & Jenkins @ LeanIX Enterprise ...
CodeTalks Vortrag: Automatisierung mit Ansible & Jenkins @ LeanIX Enterprise ...LeanIX GmbH
 
Forms and Reports 12c - Processes and Automation in Development and Operations
Forms and Reports 12c - Processes and Automation in Development and OperationsForms and Reports 12c - Processes and Automation in Development and Operations
Forms and Reports 12c - Processes and Automation in Development and OperationsTorsten Kleiber
 
Continuous Lifecycle 2013: Testgetriebenes Arbeiten im Betrieb
Continuous Lifecycle 2013: Testgetriebenes Arbeiten im BetriebContinuous Lifecycle 2013: Testgetriebenes Arbeiten im Betrieb
Continuous Lifecycle 2013: Testgetriebenes Arbeiten im BetriebAndreas Schmidt
 
System Center Configuration Manager with Azure, Intune and Application Manage...
System Center Configuration Manager with Azure, Intune and Application Manage...System Center Configuration Manager with Azure, Intune and Application Manage...
System Center Configuration Manager with Azure, Intune and Application Manage...Digicomp Academy AG
 
Nagios Conference 2007 | Eventverarbeitung mit Nagios by Michael Streb
Nagios Conference 2007 | Eventverarbeitung mit Nagios by Michael StrebNagios Conference 2007 | Eventverarbeitung mit Nagios by Michael Streb
Nagios Conference 2007 | Eventverarbeitung mit Nagios by Michael StrebNETWAYS
 
OSMC 2016 - Hello Redfish, Goodbye IPMI - The future of Hardware Monitoring
OSMC 2016 - Hello Redfish, Goodbye IPMI - The future of Hardware MonitoringOSMC 2016 - Hello Redfish, Goodbye IPMI - The future of Hardware Monitoring
OSMC 2016 - Hello Redfish, Goodbye IPMI - The future of Hardware MonitoringNETWAYS
 
OSMC 2016 | Hello Redfish, goodbye IPMI - Die Zukunft des Hardware-Monitorings
OSMC 2016 | Hello Redfish, goodbye IPMI - Die Zukunft des Hardware-MonitoringsOSMC 2016 | Hello Redfish, goodbye IPMI - Die Zukunft des Hardware-Monitorings
OSMC 2016 | Hello Redfish, goodbye IPMI - Die Zukunft des Hardware-MonitoringsNETWAYS
 
Webinar - ABAP Development Tools
Webinar - ABAP Development ToolsWebinar - ABAP Development Tools
Webinar - ABAP Development ToolsCadaxo GmbH
 
Echtes Single Sign-On mit APEX realisieren
Echtes Single Sign-On mit APEX realisierenEchtes Single Sign-On mit APEX realisieren
Echtes Single Sign-On mit APEX realisierenMT AG
 
AndroMDA - Einführung in eine Open Source Model Driven Architecture Lösung
AndroMDA - Einführung in eine Open Source Model Driven Architecture LösungAndroMDA - Einführung in eine Open Source Model Driven Architecture Lösung
AndroMDA - Einführung in eine Open Source Model Driven Architecture LösungEduard Hildebrandt
 
Cloud Deployment und (Auto)Scaling am Beispiel von Angrybird
Cloud Deployment und (Auto)Scaling am Beispiel von AngrybirdCloud Deployment und (Auto)Scaling am Beispiel von Angrybird
Cloud Deployment und (Auto)Scaling am Beispiel von AngrybirdAOE
 

Ähnlich wie OSMC 2012 | Automatische Konfiguration von Nagios/Icinga mit Agordamon by Christian Schneemann (20)

Monitoring von SAP mit check_sap_health
Monitoring von SAP mit check_sap_healthMonitoring von SAP mit check_sap_health
Monitoring von SAP mit check_sap_health
 
Some Bashing II - Mit der Kommandozeile Abläufe automatisieren
Some Bashing II - Mit der Kommandozeile Abläufe automatisierenSome Bashing II - Mit der Kommandozeile Abläufe automatisieren
Some Bashing II - Mit der Kommandozeile Abläufe automatisieren
 
System- & Konfigurationsmanagement mit Foreman & Puppet
System- & Konfigurationsmanagement mit Foreman & Puppet System- & Konfigurationsmanagement mit Foreman & Puppet
System- & Konfigurationsmanagement mit Foreman & Puppet
 
Systemmanagement mit Puppet und Foreman
Systemmanagement mit Puppet und ForemanSystemmanagement mit Puppet und Foreman
Systemmanagement mit Puppet und Foreman
 
ADR Best Practices - DOAG Regio-Treffen 2010 - OPITZ CONSULTING - Christian B...
ADR Best Practices - DOAG Regio-Treffen 2010 - OPITZ CONSULTING - Christian B...ADR Best Practices - DOAG Regio-Treffen 2010 - OPITZ CONSULTING - Christian B...
ADR Best Practices - DOAG Regio-Treffen 2010 - OPITZ CONSULTING - Christian B...
 
AdminCamp 2011 Performance
AdminCamp 2011 PerformanceAdminCamp 2011 Performance
AdminCamp 2011 Performance
 
Migrate your Sametime Server to LDAP Authentication (Admincamp 2013)
Migrate your Sametime Server to LDAP Authentication (Admincamp 2013)Migrate your Sametime Server to LDAP Authentication (Admincamp 2013)
Migrate your Sametime Server to LDAP Authentication (Admincamp 2013)
 
B1 Acocon Lotus Day 08.09.2009
B1 Acocon Lotus Day 08.09.2009B1 Acocon Lotus Day 08.09.2009
B1 Acocon Lotus Day 08.09.2009
 
CodeTalks Vortrag: Automatisierung mit Ansible & Jenkins @ LeanIX Enterprise ...
CodeTalks Vortrag: Automatisierung mit Ansible & Jenkins @ LeanIX Enterprise ...CodeTalks Vortrag: Automatisierung mit Ansible & Jenkins @ LeanIX Enterprise ...
CodeTalks Vortrag: Automatisierung mit Ansible & Jenkins @ LeanIX Enterprise ...
 
Forms and Reports 12c - Processes and Automation in Development and Operations
Forms and Reports 12c - Processes and Automation in Development and OperationsForms and Reports 12c - Processes and Automation in Development and Operations
Forms and Reports 12c - Processes and Automation in Development and Operations
 
Continuous Lifecycle 2013: Testgetriebenes Arbeiten im Betrieb
Continuous Lifecycle 2013: Testgetriebenes Arbeiten im BetriebContinuous Lifecycle 2013: Testgetriebenes Arbeiten im Betrieb
Continuous Lifecycle 2013: Testgetriebenes Arbeiten im Betrieb
 
System Center Configuration Manager with Azure, Intune and Application Manage...
System Center Configuration Manager with Azure, Intune and Application Manage...System Center Configuration Manager with Azure, Intune and Application Manage...
System Center Configuration Manager with Azure, Intune and Application Manage...
 
Nagios Conference 2007 | Eventverarbeitung mit Nagios by Michael Streb
Nagios Conference 2007 | Eventverarbeitung mit Nagios by Michael StrebNagios Conference 2007 | Eventverarbeitung mit Nagios by Michael Streb
Nagios Conference 2007 | Eventverarbeitung mit Nagios by Michael Streb
 
systemd im Alltag
systemd im Alltagsystemd im Alltag
systemd im Alltag
 
OSMC 2016 - Hello Redfish, Goodbye IPMI - The future of Hardware Monitoring
OSMC 2016 - Hello Redfish, Goodbye IPMI - The future of Hardware MonitoringOSMC 2016 - Hello Redfish, Goodbye IPMI - The future of Hardware Monitoring
OSMC 2016 - Hello Redfish, Goodbye IPMI - The future of Hardware Monitoring
 
OSMC 2016 | Hello Redfish, goodbye IPMI - Die Zukunft des Hardware-Monitorings
OSMC 2016 | Hello Redfish, goodbye IPMI - Die Zukunft des Hardware-MonitoringsOSMC 2016 | Hello Redfish, goodbye IPMI - Die Zukunft des Hardware-Monitorings
OSMC 2016 | Hello Redfish, goodbye IPMI - Die Zukunft des Hardware-Monitorings
 
Webinar - ABAP Development Tools
Webinar - ABAP Development ToolsWebinar - ABAP Development Tools
Webinar - ABAP Development Tools
 
Echtes Single Sign-On mit APEX realisieren
Echtes Single Sign-On mit APEX realisierenEchtes Single Sign-On mit APEX realisieren
Echtes Single Sign-On mit APEX realisieren
 
AndroMDA - Einführung in eine Open Source Model Driven Architecture Lösung
AndroMDA - Einführung in eine Open Source Model Driven Architecture LösungAndroMDA - Einführung in eine Open Source Model Driven Architecture Lösung
AndroMDA - Einführung in eine Open Source Model Driven Architecture Lösung
 
Cloud Deployment und (Auto)Scaling am Beispiel von Angrybird
Cloud Deployment und (Auto)Scaling am Beispiel von AngrybirdCloud Deployment und (Auto)Scaling am Beispiel von Angrybird
Cloud Deployment und (Auto)Scaling am Beispiel von Angrybird
 

OSMC 2012 | Automatische Konfiguration von Nagios/Icinga mit Agordamon by Christian Schneemann

  • 1. Automatische Konfiguration von Nagios/Icinga mit Agordamon Christian Schneemann http://www.b1-systems.de c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 2. Agenda Wege Nagios/Icinga zu konfigurieren Agordamon Warum ein weiteres Tool... Was kann es... Wofür ist es gedacht.. Wie funktioniert es... Beispiele aus der Praxis Agordamon mit Nmap Agordamon mit CMDB c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 3. Wege Nagios/Icinga zu konfigurieren Wege Nagios/Icinga zu konfigurieren c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 4. Wege Nagios/Icinga zu konfigurieren Konfigurationstools NagiosQL NConf LConf . . . $EDITOR Tools um Konfigurationen automatisch zu erstellen: u. a. Agordamon c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 5. Agordamon Agordamon http://github.com/cschneemann/agordamon [EO] agordaro ([EDV] (z.B. in Konfigurationsdateien oder der Registry) Konfigurationseinstellungen) + mon c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 6. Agordamon - Warum? viele Tools verfügbar.. Webapplikationen Datenbankgestützt einfach benutztbar.. . . . aber . . . c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 7. Agordamon - Warum? es fehlte etwas . . . Datenquellen anzapfen (CMDB, Listen, . . . ) einfach scriptbar perlbasiert flexibel . . . c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 8. Agordamon - Warum? also c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 9. Agordamon - Was kann es? Unterstützt bei der Erstellung von Nagios/Icinga Konfigurationsobjekten vorhandene Konfigurationen können eingelesen werden Objekte können in einer MongoDB zwischengespeichert werden keine vollständigen Konfigurationen nötig -> Mischbetrieb möglich c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 10. Agordamon - Wo setzt man es ein? zur initialen "Befüllung"mit anschließender manueller Überarbeitung in homogene Umgebungen, z.B. Webserverfarm, SAN Umgebungen in "Clouds", gekoppelt mit Provisionierungsscripten c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 11. Agordamon - Wo wird es eingesetzt Agordamon wird seit 2010 bei Kunden eingesetzt für. . . . . . automatische, regelbasierte Konfigurationserstellung aller Server Server der Abteilung: sortierung in Gruppen nach Teamzugehörigkeit/Kostenstelle Überwachen von definierten Standards Abgleich der Kontaktdaten/Gruppenzugehörigkeit gegen Adressbücher Zuordnung von Verantwortlichkeiten mit Listen contact Erstellung bei Neueinstellungen (Änderung im Adressbuch) c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 12. Agordamon - Wie nutzt man es? ... Arten zur Konfigurationserstellung: "write only": komplette Objektkonfiguration wird (teilweise) neu erstellt datenbankgestützt: Objekte werden in der Datenbank erstellt oder verändert gemischt: ein Teil wird neu generiert, ein Teil aus Datenbank/alten Konfigurationen c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 13. Agordamon - Wie funktioniert es? Perl Modul unabhängige Objekte keine direkten Abhängigkeiten, keine Baumstruktur ”Abhängigkeiten” durch Queries c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 14. Agordamon - Befehlsübersicht create_object($type, %definition) delete_object($type, $query) create_config(@types) c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 15. Agordamon - Befehlsübersicht create_object($type, %definition) create_object("service", name => "hostname,ssh", service_description => "SSH", host_name => "testhost23", use => "check_ssh", check_command => "check_ssh", register => "1"); c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 16. Agordamon - Befehlsübersicht delete_object($type, $query) delete_object("hosts", { host_name => "testhost05"} ); c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 17. Agordamon - Befehlsübersicht create_config(@types) create_config("host", "service"); c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 18. Agordamon - Befehlsübersicht Befehle für Gruppen: add_member2group($type, $group, $member) add_group2member($type, $host, $group) c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 19. Agordamon - Beispiel Innerhalb von Perl-Scripten: #!/usr/bin/perl use agordamon; my $an = agordamon->new(db_type => "files"); $an->create_object("host", host_name => "xen01", address => "10.10.0.23", use => "xen_hosts", register => "1" ); $an->create_object("service", name => "xen01,ssh", service_description => "SSH", host_name => "xen01", check_command => "check_ssh", use => "check_ssh", register => "1"); print $an->create_config("host", "service"); c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 20. Agordamon - Installation per RPM (openSUSE 11.4, 12.1, 12.2, Factory, Tumbleweed, weitere !SUSE folgen...) http://download.opensuse.org/repositories/home:/cschneemann/ $ tar xfzv agordamon-0.23.5.tar.gz $ perl Makefile.PL $ make # make install c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 21. Agordamon mit nmap Agordamon mit nmap c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 22. Agordamon - in Zusammenspiel mit nmap 1 Netzwerk scannen mit nmap Daten aufbereiten per snmp scan 2 Agordamonscript erstellen zum Auswerten 3 Konfiguration erstellen lassen c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 23. Agordamon - in Zusammenspiel mit nmap # nmap -O --osscan-guess -sS -F -sV -oX nmap2.xml > 192.168.178.0-255 -F fast mode -sV probe version -sS SYN -O OS detection -oX output XML c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 24. Agordamon - in Zusammenspiel mit nmap #!/usr/bin/perl use Nmap::Parser; use agordamon; my $an = agordamon->new(db_type => "files"); my $np = new Nmap::Parser; $np->parsefile($nmap_file); for my $host ($np->all_hosts()) { my $anhost = $an->create_object("host", host_name => $host->hostname(), address => $host->addr(), use => $hosts_template, register => "1" ); for my $port (@tcp_ports) { if ( $svc->name eq "ssh" ) { $an->create_object("service", name => $hostname.",ssh", service_description => "SSH", host_name => $host->hostname(), use => "check_ssh", check_command => "check_ssh", register => "1"); } } } c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 25. Agordamon - in Zusammenspiel mit inmap DEMO c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 26. Agordamon mit CMDB Agordamon mit CMDB c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 27. Agordamon - in Zusammenspiel mit CMDB 1 Export generieren 2 Agordamonscript erstellen zum Auswerten 3 Konfiguration erstellen lassen Script kann regelmäßig laufen Nagios/Icinga immer auf dem aktuellsten Stand c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 28. Agordamon - in Zusammenspiel mit CMDB DEMO c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 29. Agordamon - in Zusammenspiel mit CMDB Was kann man also mit Agordamon erreichen... c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 30. Agordamon - Einsatzmöglichkeiten Nagios/Icinga. . . . . . ’grob” vorbefüllen . . . synchron mit Datenquellen halten contacts <-> Adressbuch hosts <-> CMDB hostgruppen <-> Teams <-> CMDB/Adressbuch . . . . . . c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 31. Agordamon - die Zukunft.. intern aufräumen Code säubern FIXMEs und TODOs bearbeiten weitere Datenbanken unterstützen Objektverwaltung anderer Module nutzen (Nagios::Config) einfacher nutzbar machen mehr Beispielscripte/fertige Tools Dokumentation++ . . . c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 32. Fragen Fragen? c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012
  • 33. vielen Dank für die Aufmerksamkeit . . . doch noch Fragen? schneemann@b1-systems.de c B1 Systems GmbH 2004 – 2012 Open Source Monitoring Conference 2012