# Elasticsearch

**URL:** https://discuss.elastic.co/c/elastic-stack/elasticsearch/6.md?page=1726

[Latest](https://discuss.elastic.co/latest.md) · [Categories](https://discuss.elastic.co/categories.md) · [Tags](https://discuss.elastic.co/tags.md)

**Page:** 1727

---

## [Compare condition for checking strings in watcher is not Working?](https://discuss.elastic.co/t/compare-condition-for-checking-strings-in-watcher-is-not-working/126882)

<div class="topic-metadata">

**Author:** [@naveen\_K.N](https://discuss.elastic.co/u/naveen_K.N)\
**Replies:** 11\
**Last updated:** [April 9, 2018, 8:06am UTC](https://discuss.elastic.co/t/compare-condition-for-checking-strings-in-watcher-is-not-working/126882 "2018-04-09T08:06:11Z")

</div>

Hi Elastic Experts, we have a compare condition as follows: "condition": { "compare": { "ctx.payload.hits.hits.0.\_source.syslog\_message": { "gt": "lang.OutOfMemoryError:" } } } so here we want to check if sysl…

---

## [Load the date field from hive to elasticsearch and visualize it on kibana](https://discuss.elastic.co/t/load-the-date-field-from-hive-to-elasticsearch-and-visualize-it-on-kibana/127209)

<div class="topic-metadata">

**Author:** [@MARRAKCHI\_Tarik](https://discuss.elastic.co/u/MARRAKCHI_Tarik)\
**Replies:** 1\
**Last updated:** [April 9, 2018, 8:01am UTC](https://discuss.elastic.co/t/load-the-date-field-from-hive-to-elasticsearch-and-visualize-it-on-kibana/127209 "2018-04-09T08:01:15Z")

</div>

Hi, I have a Hive database and I connected it with es-hadoop, but I have a problem concerning the date type field, I can not load the date on elasticsearch and visualize it on Kibana, here is my problem in detail: here…

---

## [exactMatchFirst in Elastic with edge-ngram analyser](https://discuss.elastic.co/t/exactmatchfirst-in-elastic-with-edge-ngram-analyser/127265)

<div class="topic-metadata">

**Author:** [@Deepak\_r\_kiran](https://discuss.elastic.co/u/Deepak_r_kiran)\
**Replies:** 1\
**Last updated:** [April 9, 2018, 7:52am UTC](https://discuss.elastic.co/t/exactmatchfirst-in-elastic-with-edge-ngram-analyser/127265 "2018-04-09T07:52:17Z")

</div>

As per example posted in elastic website, it won't return the result with "exactMatchFirst ", What should be included in the query?. I have played around "minimum\_should\_match" but when its value is 100% then only exac…

---

## [Simple (non-nested) Multi-field terms aggregation on nested field using script](https://discuss.elastic.co/t/simple-non-nested-multi-field-terms-aggregation-on-nested-field-using-script/127257)

<div class="topic-metadata">

**Author:** [@sayali\_hinge](https://discuss.elastic.co/u/sayali_hinge)\
**Replies:** 0\
**Last updated:** [April 9, 2018, 6:54am UTC](https://discuss.elastic.co/t/simple-non-nested-multi-field-terms-aggregation-on-nested-field-using-script/127257 "2018-04-09T06:54:14Z")

</div>

As much as I understand, if we perform simple (non-nested) aggregation on a nested field, it provides each bucket containing the count of the parent document (document of which this nested field is a property). And not t…

---

## [Search API vs Count API performance?](https://discuss.elastic.co/t/search-api-vs-count-api-performance/126544)

<div class="topic-metadata">

**Author:** [@gskema](https://discuss.elastic.co/u/gskema)\
**Replies:** 3\
**Last updated:** [April 9, 2018, 6:03am UTC](https://discuss.elastic.co/t/search-api-vs-count-api-performance/126544 "2018-04-09T06:03:32Z")

</div>

Recently we made changes to our code, where we replaced a search request (with aggs, score functions, etc.) with a count request. The problem is that we can't monitor count requests with a stats group. Someone claimed t…

---

## [Java path is not set for Elastic Search](https://discuss.elastic.co/t/java-path-is-not-set-for-elastic-search/127090)

<div class="topic-metadata">

**Author:** [@Jeni](https://discuss.elastic.co/u/Jeni)\
**Replies:** 3\
**Last updated:** [April 9, 2018, 5:56am UTC](https://discuss.elastic.co/t/java-path-is-not-set-for-elastic-search/127090 "2018-04-09T05:56:17Z")

</div>

Hi All Lets start the Discussion on this Topic and i am Ubuntu 16.04 and i am downloaded and installed the version 6.2.3 using sudo dpkg -i elasticsearch-6.2.3.deb and the set up is done properly but it has some problem…

---

## [How to LDAP Connection?](https://discuss.elastic.co/t/how-to-ldap-connection/126069)

<div class="topic-metadata">

**Author:** [@Christopher\_Bogs\_Oli](https://discuss.elastic.co/u/Christopher_Bogs_Oli)\
**Replies:** 16\
**Last updated:** [April 9, 2018, 3:08am UTC](https://discuss.elastic.co/t/how-to-ldap-connection/126069 "2018-04-09T03:08:41Z")

</div>

Hi All, I am trying to integrate EFK to LDAP. My configurations in ES is. "elaticsearch.yml" //root@uklvadapp417\[DEV\]\[elasticsearch\] //# cat elasticsearch.yml //# ======================== Elasticsearch Configuration…

---

## [Need the steps to Index and mapping the unstructured log file and show the expected fields properly in kibana](https://discuss.elastic.co/t/need-the-steps-to-index-and-mapping-the-unstructured-log-file-and-show-the-expected-fields-properly-in-kibana/127236)

<div class="topic-metadata">

**Author:** [@rakeshroshan](https://discuss.elastic.co/u/rakeshroshan)\
**Replies:** 0\
**Last updated:** [April 9, 2018, 2:36am UTC](https://discuss.elastic.co/t/need-the-steps-to-index-and-mapping-the-unstructured-log-file-and-show-the-expected-fields-properly-in-kibana/127236 "2018-04-09T02:36:56Z")

</div>

I need to seperate the field values correctly, to display it in the kibana. I want to parse the unstructured log file. So i came to know with the help of Index and mapping it is possible. But i don't kow to Index and ma…

---

## [SAML for Hosted Elastic Cloud](https://discuss.elastic.co/t/saml-for-hosted-elastic-cloud/126989)

<div class="topic-metadata">

**Author:** [@jmanduca](https://discuss.elastic.co/u/jmanduca)\
**Replies:** 3\
**Last updated:** [April 8, 2018, 11:45pm UTC](https://discuss.elastic.co/t/saml-for-hosted-elastic-cloud/126989 "2018-04-08T23:45:26Z")

</div>

Hello, We were looking to incorporate SAML login for our hosted elastic cloud, however the cloud configuration option for elasticsearch.yml does not have support for the required options. Supported options listed at htt…

---

## [Status Red : "java.lang.OutOfMemoryError: Java heap space" causing unassigned shards](https://discuss.elastic.co/t/status-red-java-lang-outofmemoryerror-java-heap-space-causing-unassigned-shards/127200)

<div class="topic-metadata">

**Author:** [@maxime-benoit](https://discuss.elastic.co/u/maxime-benoit)\
**Replies:** 1\
**Last updated:** [April 8, 2018, 1:36pm UTC](https://discuss.elastic.co/t/status-red-java-lang-outofmemoryerror-java-heap-space-causing-unassigned-shards/127200 "2018-04-08T13:36:26Z")

</div>

Hi everyone, I've set an ES 4 data nodes cluster (6 threads, 32 Go of RAM, 500 Go of data each) with logstash on one of them. My goal is to put 600 Go of log data into ES using logstash, but let's start with 3 Go. Af…

---

## [Replica Shards Much Larger Than Primaries](https://discuss.elastic.co/t/replica-shards-much-larger-than-primaries/126744)

<div class="topic-metadata">

**Author:** [@Evesy](https://discuss.elastic.co/u/Evesy)\
**Replies:** 6\
**Last updated:** [April 8, 2018, 12:56pm UTC](https://discuss.elastic.co/t/replica-shards-much-larger-than-primaries/126744 "2018-04-08T12:56:49Z")

</div>

Hi, I've been seeing some strange behaviour in 6.2.3 with replica shards being x2/3/4 bigger than their corresponding primaries (Replicas: 1): \[53\] An example from /\_cat/shards: applicationlogs-2018.04.04 2 p STARTED…

---

## [Minimum\_should\_match with ngrams](https://discuss.elastic.co/t/minimum-should-match-with-ngrams/127198)

<div class="topic-metadata">

**Author:** [@Mikk\_Kiilaspaa](https://discuss.elastic.co/u/Mikk_Kiilaspaa)\
**Replies:** 0\
**Last updated:** [April 8, 2018, 8:55am UTC](https://discuss.elastic.co/t/minimum-should-match-with-ngrams/127198 "2018-04-08T08:55:44Z")

</div>

It seems to me as if I can't specify that I want more than a single ngram match on a document. Query and response here: https://pastebin.com/3ukD5yWR I'd like to only get back documents, where a word contains all or mo…

---

## [Use replace function in elasticsearch like in sql](https://discuss.elastic.co/t/use-replace-function-in-elasticsearch-like-in-sql/127191)

<div class="topic-metadata">

**Author:** [@famo](https://discuss.elastic.co/u/famo)\
**Replies:** 1\
**Last updated:** [April 8, 2018, 5:06am UTC](https://discuss.elastic.co/t/use-replace-function-in-elasticsearch-like-in-sql/127191 "2018-04-08T05:06:47Z")

</div>

Hi I know about "Pattern Replace Char Filter" but Is there any conceptlike replace function in sql ? I want to change name fileds in elasticsearch then search for my desierd name but I don;t want to save changed name i…

---

## [Fields that need not be searched or indexed](https://discuss.elastic.co/t/fields-that-need-not-be-searched-or-indexed/127186)

<div class="topic-metadata">

**Author:** [@Hooman\_Bahreini](https://discuss.elastic.co/u/Hooman_Bahreini)\
**Replies:** 2\
**Last updated:** [April 8, 2018, 1:10am UTC](https://discuss.elastic.co/t/fields-that-need-not-be-searched-or-indexed/127186 "2018-04-08T01:10:28Z")

</div>

I am using ElasticSearch v6 to search my product catalog. My product has a number fields, such as title, description, price, etc... one of the fields is: photo\_path, which would contain the location of product photo on …

---

## [NoNodeAvailableException, cannot connect SpringBoot 2.0 and Elasticsearch5.5.0](https://discuss.elastic.co/t/nonodeavailableexception-cannot-connect-springboot-2-0-and-elasticsearch5-5-0/127181)

<div class="topic-metadata">

**Author:** [@Martin\_Cuka](https://discuss.elastic.co/u/Martin_Cuka)\
**Replies:** 0\
**Last updated:** [April 7, 2018, 11:25pm UTC](https://discuss.elastic.co/t/nonodeavailableexception-cannot-connect-springboot-2-0-and-elasticsearch5-5-0/127181 "2018-04-07T23:25:44Z")

</div>

Hello, I know it was discussed several times however after reading all threads I am still not able connect SpringBoot 2.0 application to ElasticSearch 5.5.0 while using TransportClient (as Java High-Level REST Client wa…

---

## [Red status : plugin:elasticsearch@6.2.3 Service Unavailable](https://discuss.elastic.co/t/red-status-plugin-elasticsearch-6-2-3-service-unavailable/127178)

<div class="topic-metadata">

**Author:** [@maxime-benoit](https://discuss.elastic.co/u/maxime-benoit)\
**Replies:** 1\
**Last updated:** [April 7, 2018, 8:11pm UTC](https://discuss.elastic.co/t/red-status-plugin-elasticsearch-6-2-3-service-unavailable/127178 "2018-04-07T20:11:31Z")

</div>

Hi everyone, I'm very new to elasticsearch and I'm facing my first red status. My cluster has 4 data nodes (3 master candidates). Everything was perfectly working until now (so I assume my conf files are ok). What hap…

---

## [Mapper-attachment plugin for 6.x](https://discuss.elastic.co/t/mapper-attachment-plugin-for-6-x/127173)

<div class="topic-metadata">

**Author:** [@mathiasconradt](https://discuss.elastic.co/u/mathiasconradt)\
**Replies:** 1\
**Last updated:** [April 7, 2018, 7:42pm UTC](https://discuss.elastic.co/t/mapper-attachment-plugin-for-6-x/127173 "2018-04-07T19:42:53Z")

</div>

Upfront: I know about "mapper-attachments" but the plugin does not seem to be compatible with ES6, only with older versions. Detailed problem: Hi, I'm new to ElasticSearch and Logstash, coming from Solr. I am looking s…

---

## [Elasticsearch limit count result](https://discuss.elastic.co/t/elasticsearch-limit-count-result/127157)

<div class="topic-metadata">

**Author:** [@rrader](https://discuss.elastic.co/u/rrader)\
**Replies:** 13\
**Last updated:** [April 7, 2018, 7:25pm UTC](https://discuss.elastic.co/t/elasticsearch-limit-count-result/127157 "2018-04-07T19:25:32Z")

</div>

How in Elasticsearch to limit count result to maximum of 1000? So, If count have 400 results, then it respond with 400, if count have 1200, it repond with 1000.

---

## [Elasticsearch query on multiple fields with custom weight](https://discuss.elastic.co/t/elasticsearch-query-on-multiple-fields-with-custom-weight/126141)

<div class="topic-metadata">

**Author:** [@vishnu-team8](https://discuss.elastic.co/u/vishnu-team8)\
**Replies:** 1\
**Last updated:** [April 7, 2018, 5:37pm UTC](https://discuss.elastic.co/t/elasticsearch-query-on-multiple-fields-with-custom-weight/126141 "2018-04-07T17:37:26Z")

</div>

Let's say my index has name and skills. { "name": "Vishnu Prasad", "skills": \["devops", "ruby"\] } { "name": "Prasad", "skills": \["ruby"\] } { "name": "Jonathan", "skills": \["devops"\] } { "name": "V…

---

## [Configuring ELK via tar.gz](https://discuss.elastic.co/t/configuring-elk-via-tar-gz/127163)

<div class="topic-metadata">

**Author:** [@adg](https://discuss.elastic.co/u/adg)\
**Replies:** 1\
**Last updated:** [April 7, 2018, 4:52pm UTC](https://discuss.elastic.co/t/configuring-elk-via-tar-gz/127163 "2018-04-07T16:52:25Z")

</div>

I m new user of ELKF but when i first use it via \*.tar.gz where i just copy and paste and extracted at one place (i use /opt/) on other system i use .deb package which create system user of each service and also got s…

---

## [Temporary table alternative in elastic search](https://discuss.elastic.co/t/temporary-table-alternative-in-elastic-search/127160)

<div class="topic-metadata">

**Author:** [@Vaibhav\_Kumar](https://discuss.elastic.co/u/Vaibhav_Kumar)\
**Replies:** 2\
**Last updated:** [April 7, 2018, 11:03am UTC](https://discuss.elastic.co/t/temporary-table-alternative-in-elastic-search/127160 "2018-04-07T11:03:11Z")

</div>

I have a scenerio where i'm filtering some records from a table and reusing the same intermediate tables to join on a column. My query looks something like this select \* from (select poscode from test where AccountNo…

---

## [Pagination and limit max number of pages](https://discuss.elastic.co/t/pagination-and-limit-max-number-of-pages/127096)

<div class="topic-metadata">

**Author:** [@rrader](https://discuss.elastic.co/u/rrader)\
**Replies:** 3\
**Last updated:** [April 7, 2018, 8:43am UTC](https://discuss.elastic.co/t/pagination-and-limit-max-number-of-pages/127096 "2018-04-07T08:43:21Z")

</div>

We want to filter products, by search term, category, price, location, and a few more. In Elasticsearch deep paging is problematic, but if we limit to 20 items per page and max number of pages to 100, will be this ok? h…

---

## [Extract relevant documents when search input may/may not contain white space](https://discuss.elastic.co/t/extract-relevant-documents-when-search-input-may-may-not-contain-white-space/127040)

<div class="topic-metadata">

**Author:** [@sobiya](https://discuss.elastic.co/u/sobiya)\
**Replies:** 3\
**Last updated:** [April 7, 2018, 8:40am UTC](https://discuss.elastic.co/t/extract-relevant-documents-when-search-input-may-may-not-contain-white-space/127040 "2018-04-07T08:40:25Z")

</div>

Hi all, I can extract the documents with/without space. But if i give input with space (without space in index),the relevant documents are not hitting at the top. Need to score high when compared to other documents. Fo…

---

## [Single host OS, multiple nodes for simplicity over availability](https://discuss.elastic.co/t/single-host-os-multiple-nodes-for-simplicity-over-availability/125814)

<div class="topic-metadata">

**Author:** [@rfs42](https://discuss.elastic.co/u/rfs42)\
**Replies:** 12\
**Last updated:** [April 7, 2018, 8:38am UTC](https://discuss.elastic.co/t/single-host-os-multiple-nodes-for-simplicity-over-availability/125814 "2018-04-07T08:38:28Z")

</div>

I'm interested in building a log management Elasticsearch implementation with simplicity prioritized over availability. We can live with some down time, but not data loss, and our upstream infrastructure will accumulat…

---

## [How to use the ElasticSearch Java API to build an Aggregation from JSON](https://discuss.elastic.co/t/how-to-use-the-elasticsearch-java-api-to-build-an-aggregation-from-json/70773)

<div class="topic-metadata">

**Author:** [@jonskeet](https://discuss.elastic.co/u/jonskeet)\
**Replies:** 4\
**Last updated:** [April 7, 2018, 3:01am UTC](https://discuss.elastic.co/t/how-to-use-the-elasticsearch-java-api-to-build-an-aggregation-from-json/70773 "2018-04-07T03:01:38Z")

</div>

Hi everyone, My code has an ElasticSearch query and aggregations in JSON format, and wants to call the ElasticSearch Java API. For the Query portion, I can use WrapperQuery to build the query from the JSON as so: v…

---

## [How to access doc values in LeafScoreFunction (noobie)](https://discuss.elastic.co/t/how-to-access-doc-values-in-leafscorefunction-noobie/127112)

<div class="topic-metadata">

**Author:** [@stephencoffman](https://discuss.elastic.co/u/stephencoffman)\
**Replies:** 2\
**Last updated:** [April 6, 2018, 10:01pm UTC](https://discuss.elastic.co/t/how-to-access-doc-values-in-leafscorefunction-noobie/127112 "2018-04-06T22:01:17Z")

</div>

ES 6.2.3 I'm trying to write a SearchPlugin to do custom scoring, but I can't figure out how to access the doc values in my leaf score function. The LeafScoreFunction.score() method takes a docId parameter. Is there a…

---

## [Best practice for creating an index when an ES docker container starts](https://discuss.elastic.co/t/best-practice-for-creating-an-index-when-an-es-docker-container-starts/126651)

<div class="topic-metadata">

**Author:** [@Brett\_Anderson](https://discuss.elastic.co/u/Brett_Anderson)\
**Replies:** 4\
**Last updated:** [April 6, 2018, 9:26pm UTC](https://discuss.elastic.co/t/best-practice-for-creating-an-index-when-an-es-docker-container-starts/126651 "2018-04-06T21:26:07Z")

</div>

When running an initialization script to create a new index on startup, authentication fails with default username and password (elastic:changeme). Waiting a few seconds then manually running the exact same command works…

---

## [Match\_all in a filter context](https://discuss.elastic.co/t/match-all-in-a-filter-context/127133)

<div class="topic-metadata">

**Author:** [@Doug\_Nelson1](https://discuss.elastic.co/u/Doug_Nelson1)\
**Replies:** 1\
**Last updated:** [April 6, 2018, 7:41pm UTC](https://discuss.elastic.co/t/match-all-in-a-filter-context/127133 "2018-04-06T19:41:30Z")

</div>

Working on a search template and the query has three optional parameters that will form three term filter statements in a must clause. So because of this I need basically a match\_all in this clause so if none of these …

---

## [Deploy Elastic Search with Kubernetes StatefulSet cannot persist the index data](https://discuss.elastic.co/t/deploy-elastic-search-with-kubernetes-statefulset-cannot-persist-the-index-data/126484)

<div class="topic-metadata">

**Author:** [@Bai](https://discuss.elastic.co/u/Bai)\
**Replies:** 2\
**Last updated:** [April 6, 2018, 5:15pm UTC](https://discuss.elastic.co/t/deploy-elastic-search-with-kubernetes-statefulset-cannot-persist-the-index-data/126484 "2018-04-06T17:15:29Z")

</div>

Hi All, I'm deploying Elastic Search as StatefulSet in Kubernetes, but cannot make the persistent volume working properly. (Reference: https://github.com/pires/kubernetes-elasticsearch-cluster/tree/master/stateful, I do…

---

## [X-Pack monitoring with different rates depending on zoom level](https://discuss.elastic.co/t/x-pack-monitoring-with-different-rates-depending-on-zoom-level/126945)

<div class="topic-metadata">

**Author:** [@webrod](https://discuss.elastic.co/u/webrod)\
**Replies:** 1\
**Last updated:** [April 6, 2018, 4:53pm UTC](https://discuss.elastic.co/t/x-pack-monitoring-with-different-rates-depending-on-zoom-level/126945 "2018-04-06T16:53:22Z")

</div>

Charts report different rates depending on the period. This apply to all X-pack monitoring charts from Kibana. Here is an example with "Beat" monitoring, with the period " week to date": \[image\] Did I really process …

[Previous page](https://discuss.elastic.co/c/elastic-stack/elasticsearch/6.md?page=1725)

[Next page](https://discuss.elastic.co/c/elastic-stack/elasticsearch/6.md?page=1727)
