SCOP d'ingénieurs experts du logiciel libre depuis 2004
+33 1 70 61 60 16

Kibana naked

Kibana is a visualising tool for Logstash project, a generic log management tool. Logstash is fed from different logging sources, and indexes them with Elastic...

Notre prochain webinar

Kibana is a visualising tool for Logstash project, a generic log management tool. Logstash is fed from different logging sources, and indexes them with Elastic Search . Kibana queries Elastic Search and displays results, with a nice and simple user interface. The third version of Kibana is now an Elastic Search sub project, an Angularjs application (pure javascript) using ajax for querying its index.

Kibana seems to be a killer application for spreading elastic search beyond full text search domain. Logstash seems to be a nice tool, too. Eating two good cakes at the same time ? Let's be abstemious and try Kibana alone.

Kibana is a simple static html website, dead simple to install. Elastic Search is easy to install, too. Using Elastic search from a web page is simple, but a bit ugly: same domain, port 9200. Please never do that on a public website. Elastic Search is naked, anybody can do anything, reading and writing. Kibana documentation explains how to use nginx as a proxy with authentication.

Parsing logs is a bit boring, and Logstash provides powerful tools for that. Lets try reading mails, Kibana needs lots of items with a date. Python mail parsing tools are broken, but Lamson provides ultimate mail reading tool, and my Thunderbird use classical mbox format. Don't even try to use Thunderbird mork index, they are doomed.

Kibana document model is simple. Few keys beginning with a @, tags and free style fields values. Here is a simple prototype with python, using two libraries :

pip install lamson pyelasticsearch 

The script is simple : iterate over emails, build documents and index them. Two arguments are used : Elastic Search url and path to a mailbox.

Use a "since date" in the UI, your mails should receive less events than your syslog.

Kibana 3 is a nice tool, still young, easy to deploy, easy to hack, but the UX needs some love.


Mathieu Lecarme

Inscrivez-vous à notre newsletter

Mieux comprendre le monde du DevOps et de l'administration système.

Abonnez-vous à notre newsletter

Hébergement & Infogérance

  • ✓ Service Astreinte 24h/7j/365
  • ✓ Supervision, monitoring & Alertes
  • ✓ Mises à jour en continu
  • ✓ Certificat SSL letsencrypt
  • ✓ Hébergement dédié sécurisé en France
  • ✓ Backup vers datacenter distant
Découvrir notre offre

Expertise Technologique

Notre équipe possède une vaste expertise technologique.