Toshaan Bharvani – Icinga2 and Ansible, how to manage and migrate
1. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
Icinga2 through Ansible
Monitoring migration through automation
Toshaan Bharvani - VanTosh bvba
<toshaan@vantosh.com>
Icinga Camp Antwerp 2015
13 April 2015
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 1 / 23
2. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
$ whoami
Toshaan Bharvani - VanTosh
From Antwerp, Belgium
Self-employed engineer/trainer (available for hire)
http://www.vantosh.com
Involved with Enterprise OS : RHEL, CentOS, IBM AIX,
OpenBSD, FreeBSD, SLES, . . .
Likes to keep everything secure : SELinux, WebSec, . . .
Lives in a virtual world : KVM, Xen, LXC, PowerVM, z/VM, . . .
Likes automation : Ansible, Puppet, Salt
Works on both hardware and software side
Wants to take over the world
Twitter : @toshywoshy
Blog : http://www.toshaan.com
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 2 / 23
3. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
Table of contents
1 Ansible
What is Ansible?
Inventory
2 Virtual Machines
3 DEMO
4 Conclusion
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 3 / 23
4. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
Monitoring Sucks!
Nagios
Zenoss
Zabbix
Ganglia
Icinga
OpsView
Shinken
Icinga2
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 4 / 23
5. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
1
Ansible
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 5 / 23
6. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
“Ansible is a fictional machine capable of instantaneous or
superluminal communication. Typically it is depicted as a
lunch-box-sized object with some combination of microphone, speaker,
keyboard and display. It can send and receive messages to and from a
corresponding device over any distance whatsoever with no delay.”1
Configuration Management Tool
System Orchestration Tool
Remote Execution/Deployment Tool
. . .
1Rocannon’s World - Ursula K. Le Guin
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 6 / 23
7. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
An overview
Python2 based
Server based, agentless2
uses SSH (can use accelerated mode uses a daemon and port)
host information in flat files, CMDB, scripts, . . .
executes a task on the host side
Playbook : combination of tasks with meta information
YAML
JSON
Templates : Jinja2
works where Python2 works3
2Abstraction of SSH and in certain setup an agent might be required, but by default it is not necessary
3Ansible can actually run without Python on the remote host, however it is not fully supported
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 7 / 23
8. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
Internal Design
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 8 / 23
9. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
Normal Adhoc Mode
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 9 / 23
10. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
Delegation Mode
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 10 / 23
18. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
3
DEMO
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 18 / 23
19. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
Demo
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 19 / 23
20. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
4
Conclusion
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 20 / 23
21. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
Conclusion
Automation MUST
[RFC2119] be easy
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 21 / 23
22. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
More information
Icinga : http://www.icinga.org
Ansible : http://www.ansible.com/
Ansible Install VM : https:
//github.com/toshywoshy/ansible-roles-vminstall
Ansible Roles Icinga :
https://github.com/toshywoshy/ansible-roles-icinga2
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 22 / 23
23. Icinga2 through
Ansible
Toshaan
Bharvani -
VanTosh bvba
Ansible
What is
Ansible?
Inventory
Virtual Machines
DEMO
Conclusion
The End
The End
Thank You
Toshaan Bharvani - VanTosh bvba <toshaan@vantosh.com>
http://www.vantosh.com/
Made with Beamer LATEX
a TEXbased Presentation program
Icinga2 through Ansible Toshaan Bharvani - VanTosh bvba 23 / 23