# Kibana vs Elastic Search

**URL:** <https://discuss.elastic.co/t/kibana-vs-elastic-search/36298>\
**Category:** Kibana\
**Created:** [December 3, 2015, 3:09pm UTC](https://discuss.elastic.co/t/kibana-vs-elastic-search/36298 "2015-12-03T15:09:52Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![chsotr](https://avatars.discourse-cdn.com/v4/letter/c/b77776/32.png) [@chsotr](https://discuss.elastic.co/u/chsotr)\
**Post date:** [December 3, 2015, 3:09pm UTC](https://discuss.elastic.co/t/kibana-vs-elastic-search/36298/1 "2015-12-03T15:09:52Z")

</div>

We do know that whenever we want to search anything related  
to Kibana it takes us to Elastic Search page, but since I don't perform  
searches using Elastic Search that is not helpful at all. What I am  
actually looking for is query instructions for Kibana which is the front  
end I use for Elastic Search.

Is there any documentation related to Kibana queries only?

-Arithmetic

-Regex

-Counting

-Number of elements(events, logs) equals zero so I can alert whenever logstash stop running(shipping event)

-Create field on Search time

Maybe Examples could be add to the Elastic Search page, how certain ES query would look like in Kibana,

Thank you,

---

<div class="post-metadata">

**Author:** ![magnusbaeck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/magnusbaeck/32/44943_2.png) [@magnusbaeck](https://discuss.elastic.co/u/magnusbaeck)\
**Post date:** [December 3, 2015, 3:18pm UTC](https://discuss.elastic.co/t/kibana-vs-elastic-search/36298/2 "2015-12-03T15:18:10Z")

</div>

It's not easy to understand what you're asking but I'll try to answer.

Kibana has no public API of its own so if you want to make queries from e.g. a script to find out when Logstash stops sending messages you should go straight to Elasticsearch instead. The query language used in e.g. the discover tab of Kibana isn't Kibana-specific but just a frontend to the Elasticsearch query language (which is really just Lucene's query language).

---

<div class="post-metadata">

**Author:** ![Cylindric](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/cylindric/32/5660_2.png) [@Cylindric](https://discuss.elastic.co/u/Cylindric)\
**Post date:** [December 3, 2015, 3:30pm UTC](https://discuss.elastic.co/t/kibana-vs-elastic-search/36298/3 "2015-12-03T15:30:50Z")

</div>

For basic searching information, I found the [Kibana Queries](https://www.elastic.co/guide/en/kibana/3.0/queries.html) page, and the [Lucene Syntax](https://lucene.apache.org/core/2_9_4/queryparsersyntax.html) page are both quite useful.

As @magnusbaeck says, to do the clever aggregation, you'll have to query ES directly and handle the results.

For example, I use a POST request to the elasticsearch backend using something like `curl` or Postman. That way you can build all the filtering and aggregation in that you need. Admittedly, building the json for an aggregated search definition for ES can be a little daunting. I searched the internet for [some tutorials](https://qbox.io/blog/elasticsearch-aggregations), as the ES documentation is a little technical for my abilities.

---

<div class="post-metadata">

**Author:** ![chsotr](https://avatars.discourse-cdn.com/v4/letter/c/b77776/32.png) [@chsotr](https://discuss.elastic.co/u/chsotr)\
**Post date:** [December 3, 2015, 3:31pm UTC](https://discuss.elastic.co/t/kibana-vs-elastic-search/36298/4 "2015-12-03T15:31:30Z")

</div>

Sorry if I was not to specific on my question,

I would like to apply whatever search example we have for Elastic Search on the discover tab of kibana.

---

<div class="post-metadata">

**Author:** ![chsotr](https://avatars.discourse-cdn.com/v4/letter/c/b77776/32.png) [@chsotr](https://discuss.elastic.co/u/chsotr)\
**Post date:** [December 3, 2015, 3:39pm UTC](https://discuss.elastic.co/t/kibana-vs-elastic-search/36298/5 "2015-12-03T15:39:16Z")

</div>

Yes, building Json is not the best approach in our case, since to build even simple queries using Curl would be too time consuming. Besides that is what Kibana is for anyway, but there seems to be huge limitations(or lack of documentation) when it comes to build more elaborated/advanced queries using Kibana instead of Elastic Search.

---

<div class="post-metadata">

**Author:** ![Cylindric](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/cylindric/32/5660_2.png) [@Cylindric](https://discuss.elastic.co/u/Cylindric)\
**Post date:** [December 3, 2015, 3:43pm UTC](https://discuss.elastic.co/t/kibana-vs-elastic-search/36298/6 "2015-12-03T15:43:08Z")

</div>

As far as I can gather (and I'm still pretty new with the ELK stack) is that the Kibana "Discover" screen is more about showing a subset of an index filtered using the Lucene syntax, and not about performing any aggregations or calculations on those results. So it's basically a "search the index" tool.

The Visualise (and through them, dashboards) are used to aggregate those results and perform all sorts of statistical analysis of the results.

You could look at [Elastic Watcher](https://www.elastic.co/products/watcher), that might do what you need with regards to alerting and monitoring, but I've not used it, so your mileage may vary.

---

<div class="post-metadata">

**Author:** ![chsotr](https://avatars.discourse-cdn.com/v4/letter/c/b77776/32.png) [@chsotr](https://discuss.elastic.co/u/chsotr)\
**Post date:** [December 3, 2015, 3:44pm UTC](https://discuss.elastic.co/t/kibana-vs-elastic-search/36298/7 "2015-12-03T15:44:36Z")

</div>

All these links you posted I have already seen as well, but they don't seem to be useful for me since they are all related to Elastic Search, which is not what I use to build my queries. I hope there is a way to understand better how Elastic Search queries can be written in a Kibana query version

---

<div class="post-metadata">

**Author:** ![Cylindric](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/cylindric/32/5660_2.png) [@Cylindric](https://discuss.elastic.co/u/Cylindric)\
**Post date:** [December 3, 2015, 3:48pm UTC](https://discuss.elastic.co/t/kibana-vs-elastic-search/36298/8 "2015-12-03T15:48:55Z")

</div>

The first two links I posted in my first reply are for Kibana - they are _not_ ES queries, and they won't work in ES.

My previous reply to this one answers that you _can't_ do the aggregation and counting that you want to do in the Discovery screen. For that you _have_ to use visualisations.\*

* * *

(\*unless someone more knowledgable jumps in and corrects me, but I've not seen any mention or sign of that ability anywhere so far)

---

<div class="post-metadata">

**Author:** ![chsotr](https://avatars.discourse-cdn.com/v4/letter/c/b77776/32.png) [@chsotr](https://discuss.elastic.co/u/chsotr)\
**Post date:** [December 3, 2015, 4:04pm UTC](https://discuss.elastic.co/t/kibana-vs-elastic-search/36298/9 "2015-12-03T16:04:39Z")

</div>

Cylindric,

That is exactly what I thought. When I post this comment and asked those question I was trying to confirm our thoughts. Kibana is more for visual report of what has been shipped by logstash. Any calculation or advanced query it seems that we will not be able to perform in Kibana. I am certainly looking at Elastic Watcher to see if we can use this tool to better apply our needs. If don't I might need to look into build our own tool to supply what kibana is not able to do and with curl would be too time consuming,

Thank you for the help! much appreciated

---

<div class="post-metadata">

**Author:** ![Cylindric](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/cylindric/32/5660_2.png) [@Cylindric](https://discuss.elastic.co/u/Cylindric)\
**Post date:** [December 3, 2015, 4:10pm UTC](https://discuss.elastic.co/t/kibana-vs-elastic-search/36298/10 "2015-12-03T16:10:39Z")

</div>

You can, you just have to use the visualisations. So use the Discovery to limit your records to what you want, and then create a visualisation based on that search that aggregates your record data. That could even just be the visualisation that shows a total number (Metric) or a chart of some sort. If you want something that looks more like data, try the Data Table visualisation.

---

<div class="post-metadata">

**Author:** ![chsotr](https://avatars.discourse-cdn.com/v4/letter/c/b77776/32.png) [@chsotr](https://discuss.elastic.co/u/chsotr)\
**Post date:** [December 3, 2015, 4:57pm UTC](https://discuss.elastic.co/t/kibana-vs-elastic-search/36298/11 "2015-12-03T16:57:03Z")

</div>

Yes, I will be using kibana more for visualization and research Watcher to see if I can apply the alerts and calculations I need,

Thanks again

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 2:07pm UTC](https://discuss.elastic.co/t/kibana-vs-elastic-search/36298/12 "2017-07-06T14:07:33Z")

</div>


