# Elasticsearch

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

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

**Page:** 1208

---

## [Unable to connect elastic search with node.js client](https://discuss.elastic.co/t/unable-to-connect-elastic-search-with-node-js-client/193084)

<div class="topic-metadata">

**Author:** [@Jin1129](https://discuss.elastic.co/u/Jin1129)\
**Replies:** 0\
**Last updated:** [July 31, 2019, 9:44am UTC](https://discuss.elastic.co/t/unable-to-connect-elastic-search-with-node-js-client/193084 "2019-07-31T09:44:52Z")

</div>

I'm trying to use elastic search client for node.js I was able to get a response with my curl command However, my client for node.js it didn't print out any result or error message. my working Curl is shown as follow …

---

## [Hi, I was using ElasticSearch Basic with single node, now I would like have one more node, does this requirement still holds good for Basic or is there any cost involved](https://discuss.elastic.co/t/hi-i-was-using-elasticsearch-basic-with-single-node-now-i-would-like-have-one-more-node-does-this-requirement-still-holds-good-for-basic-or-is-there-any-cost-involved/193248)

<div class="topic-metadata">

**Author:** [@bharatwaj](https://discuss.elastic.co/u/bharatwaj)\
**Replies:** 3\
**Last updated:** [August 1, 2019, 5:26am UTC](https://discuss.elastic.co/t/hi-i-was-using-elasticsearch-basic-with-single-node-now-i-would-like-have-one-more-node-does-this-requirement-still-holds-good-for-basic-or-is-there-any-cost-involved/193248 "2019-08-01T05:26:49Z")

</div>

I am currently using Basic with just one node and wish to create one more. I wanted to know if it could be achieved with Basic or do I have to pay to get one more node.

---

## [Elasticsearch ILM rollover from hot to warm phase not happening even when the condition for rollover is met](https://discuss.elastic.co/t/elasticsearch-ilm-rollover-from-hot-to-warm-phase-not-happening-even-when-the-condition-for-rollover-is-met/193235)

<div class="topic-metadata">

**Author:** [@ElkNovice](https://discuss.elastic.co/u/ElkNovice)\
**Replies:** 7\
**Last updated:** [August 1, 2019, 4:05am UTC](https://discuss.elastic.co/t/elasticsearch-ilm-rollover-from-hot-to-warm-phase-not-happening-even-when-the-condition-for-rollover-is-met/193235 "2019-08-01T04:05:20Z")

</div>

Elasticsearch version 7.1 I have created ILM policy as per which if the index grows more than 50 GB in size or is more than 15days old the index should rollover to warm phase. In my env, this is not happening consistent…

---

## [Monitoring indices not created](https://discuss.elastic.co/t/monitoring-indices-not-created/192786)

<div class="topic-metadata">

**Author:** [@mstarensier](https://discuss.elastic.co/u/mstarensier)\
**Replies:** 2\
**Last updated:** [August 1, 2019, 2:39am UTC](https://discuss.elastic.co/t/monitoring-indices-not-created/192786 "2019-08-01T02:39:18Z")

</div>

I'm running a new prod 7.2 cluster. Want to view my ES logs in kibana as I did in dev cluster. I understand recommendation to use a seperate monitoring cluster, but for now, just want local. I set my cluster settings s…

---

## [Does increasing number of routing shards for an index makes aggregations slower?](https://discuss.elastic.co/t/does-increasing-number-of-routing-shards-for-an-index-makes-aggregations-slower/193229)

<div class="topic-metadata">

**Author:** [@praveengadugin1](https://discuss.elastic.co/u/praveengadugin1)\
**Replies:** 0\
**Last updated:** [July 31, 2019, 11:16pm UTC](https://discuss.elastic.co/t/does-increasing-number-of-routing-shards-for-an-index-makes-aggregations-slower/193229 "2019-07-31T23:16:53Z")

</div>

aggregations performance seems to be slower after i increased number of routing shards. Is there any relation between them??

---

## [Difference between bool-should-match vs terms query on keyword/numeric field](https://discuss.elastic.co/t/difference-between-bool-should-match-vs-terms-query-on-keyword-numeric-field/193207)

<div class="topic-metadata">

**Author:** [@RahulD](https://discuss.elastic.co/u/RahulD)\
**Replies:** 1\
**Last updated:** [July 31, 2019, 10:04pm UTC](https://discuss.elastic.co/t/difference-between-bool-should-match-vs-terms-query-on-keyword-numeric-field/193207 "2019-07-31T22:04:49Z")

</div>

If I have a field in ES which is either keyword or numeric(integer/long), is there any difference between performing a bool-should\[match,match,match\] query vs a terms query?

---

## [Elasticsearch: aggregation and select docs only having max value of field](https://discuss.elastic.co/t/elasticsearch-aggregation-and-select-docs-only-having-max-value-of-field/193197)

<div class="topic-metadata">

**Author:** [@Mihir\_Kothari](https://discuss.elastic.co/u/Mihir_Kothari)\
**Replies:** 2\
**Last updated:** [July 31, 2019, 8:45pm UTC](https://discuss.elastic.co/t/elasticsearch-aggregation-and-select-docs-only-having-max-value-of-field/193197 "2019-07-31T20:45:35Z")

</div>

I am using elastic search 6.5. Basically, based on my query my index can return multiple documents, I need only those documents which has the max value for a particular field. E.g. { "query": { "bool": { …

---

## [Java High Level REST Client: Slow BooleanQuery with Filters](https://discuss.elastic.co/t/java-high-level-rest-client-slow-booleanquery-with-filters/193185)

<div class="topic-metadata">

**Author:** [@bjliu](https://discuss.elastic.co/u/bjliu)\
**Replies:** 0\
**Last updated:** [July 31, 2019, 4:55pm UTC](https://discuss.elastic.co/t/java-high-level-rest-client-slow-booleanquery-with-filters/193185 "2019-07-31T16:55:52Z")

</div>

I am struggling to figure out how to optimize this query for the Java High Level Rest Client. The code below takes about 500 milliseconds when I used Java VisualVM to profile the code. When I ran an equivalent call on …

---

## [Asd\_\_\_](https://discuss.elastic.co/t/asd/192696)

<div class="topic-metadata">

**Author:** [@anon20829737](https://discuss.elastic.co/u/anon20829737)\
**Replies:** 1\
**Last updated:** [July 29, 2019, 2:27pm UTC](https://discuss.elastic.co/t/asd/192696 "2019-07-29T14:27:09Z")

</div>

I have two situations: situation\_1: When input is "\_source" but not getting any output from ES asdddddddddda adsa dda ad as das d a d sa And I get the required the results from ES: { "took": 5, "tim…

---

## [Custom routing and multiple indexes where shard distribution is uniform](https://discuss.elastic.co/t/custom-routing-and-multiple-indexes-where-shard-distribution-is-uniform/193144)

<div class="topic-metadata">

**Author:** [@IanRC72](https://discuss.elastic.co/u/IanRC72)\
**Replies:** 2\
**Last updated:** [July 31, 2019, 6:48pm UTC](https://discuss.elastic.co/t/custom-routing-and-multiple-indexes-where-shard-distribution-is-uniform/193144 "2019-07-31T18:48:55Z")

</div>

I have an index a with a custom routing field (an int64). I have a second index b, which is a pseudo-child of a. It shares the same custom routing value as a for "child" documents. In other words, without using a parent…

---

## [Okta and xpack "Basic" subscription limitation clarification](https://discuss.elastic.co/t/okta-and-xpack-basic-subscription-limitation-clarification/193167)

<div class="topic-metadata">

**Author:** [@mhoydis\_datto](https://discuss.elastic.co/u/mhoydis_datto)\
**Replies:** 2\
**Last updated:** [July 31, 2019, 6:24pm UTC](https://discuss.elastic.co/t/okta-and-xpack-basic-subscription-limitation-clarification/193167 "2019-07-31T18:24:26Z")

</div>

If one has only the free "Basic" subscription for elasticsearch 7.x, what restrictions would they have if their userbase logs into Kibana via SAML and Okta? Is the limitation that all users from that realm would essenti…

---

## [Elasticsearch helm-charts path.logs](https://discuss.elastic.co/t/elasticsearch-helm-charts-path-logs/190449)

<div class="topic-metadata">

**Author:** [@xodn0812](https://discuss.elastic.co/u/xodn0812)\
**Replies:** 1\
**Last updated:** [July 31, 2019, 5:08pm UTC](https://discuss.elastic.co/t/elasticsearch-helm-charts-path-logs/190449 "2019-07-31T17:08:36Z")

</div>

I use the elasticsearch helm chart. However, even if path.logs is set as below, no log is generated. path.logs: /usr/share/elasticsearch/logs Do I have to make other settings?

---

## [Obtain last 2 elements of nested object and perform logic on them](https://discuss.elastic.co/t/obtain-last-2-elements-of-nested-object-and-perform-logic-on-them/193177)

<div class="topic-metadata">

**Author:** [@hv09](https://discuss.elastic.co/u/hv09)\
**Replies:** 0\
**Last updated:** [July 31, 2019, 4:22pm UTC](https://discuss.elastic.co/t/obtain-last-2-elements-of-nested-object-and-perform-logic-on-them/193177 "2019-07-31T16:22:27Z")

</div>

Hello all, I've been reading ES docs, SO and this forums' posts about this for the past 2 days, but I can't seem to figure it out. Given this data structure, which is a part of a bigger data structure that represents a…

---

## [Running cardinality for more than 10000 buckets](https://discuss.elastic.co/t/running-cardinality-for-more-than-10000-buckets/192717)

<div class="topic-metadata">

**Author:** [@divyang](https://discuss.elastic.co/u/divyang)\
**Replies:** 13\
**Last updated:** [July 31, 2019, 4:07pm UTC](https://discuss.elastic.co/t/running-cardinality-for-more-than-10000-buckets/192717 "2019-07-31T16:07:25Z")

</div>

Hi, I am making a project to get the unique number of userids per url in in our index . Index has more than 5000 urls and far more number of users ids. To the get the unique number if user ids i am using cardinality o…

---

## [Will Elasticsearch APIs support gRPC in the near future](https://discuss.elastic.co/t/will-elasticsearch-apis-support-grpc-in-the-near-future/193164)

<div class="topic-metadata">

**Author:** [@petra](https://discuss.elastic.co/u/petra)\
**Replies:** 2\
**Last updated:** [July 31, 2019, 3:57pm UTC](https://discuss.elastic.co/t/will-elasticsearch-apis-support-grpc-in-the-near-future/193164 "2019-07-31T15:57:29Z")

</div>

Hi, My team is exploring the use case of having Elasticsearch as a primary datastore for a microservices container based application architecture. As a part of our exploration we are using gRPC/Protobuf for the communic…

---

## [Too many and too frequent Un assigned shards](https://discuss.elastic.co/t/too-many-and-too-frequent-un-assigned-shards/193141)

<div class="topic-metadata">

**Author:** [@Santosh\_Singh1](https://discuss.elastic.co/u/Santosh_Singh1)\
**Replies:** 3\
**Last updated:** [July 31, 2019, 3:55pm UTC](https://discuss.elastic.co/t/too-many-and-too-frequent-un-assigned-shards/193141 "2019-07-31T15:55:44Z")

</div>

Hi All, I am pretty new to Elastic search and going thru lot of documents to understand the internals so as to optimize our cluster. Our 28 Data node and 5 Master node Elastic search (6.1) cluster is facing very freque…

---

## [Is it possible to reference the outer object in a nested query?](https://discuss.elastic.co/t/is-it-possible-to-reference-the-outer-object-in-a-nested-query/193171)

<div class="topic-metadata">

**Author:** [@PeledYuval](https://discuss.elastic.co/u/PeledYuval)\
**Replies:** 0\
**Last updated:** [July 31, 2019, 3:53pm UTC](https://discuss.elastic.co/t/is-it-possible-to-reference-the-outer-object-in-a-nested-query/193171 "2019-07-31T15:53:22Z")

</div>

Hi everybody, First of all- thanks in advance for helping. I'm running on Elastic 5.6 (I know, we should upgrade). I have an index that holds documents with a nested property. Simplified: { "mappings": { "my\_type"…

---

## [Elasticsearch Node failed to send join request to master](https://discuss.elastic.co/t/elasticsearch-node-failed-to-send-join-request-to-master/193009)

<div class="topic-metadata">

**Author:** [@xiang-liu-exa](https://discuss.elastic.co/u/xiang-liu-exa)\
**Replies:** 2\
**Last updated:** [July 31, 2019, 3:34pm UTC](https://discuss.elastic.co/t/elasticsearch-node-failed-to-send-join-request-to-master/193009 "2019-07-31T15:34:28Z")

</div>

Elasticsearch version 6.2.4 Cluster: 46 Nodes, Master: host1-0 Cluster is running for 4 days without any problem. About 10 hour ago, one data Node: host9-0 fail to ping master After that, host9-0 keeps send join requ…

---

## [Daily rollover with ILM](https://discuss.elastic.co/t/daily-rollover-with-ilm/188438)

<div class="topic-metadata">

**Author:** [@juanarmentia](https://discuss.elastic.co/u/juanarmentia)\
**Replies:** 7\
**Last updated:** [July 31, 2019, 2:20pm UTC](https://discuss.elastic.co/t/daily-rollover-with-ilm/188438 "2019-07-31T14:20:22Z")

</div>

Hi, I have an index named "winlogbeat-7.1.1-2019.07.02-000001" and I want to rollover every day. I have define a lifecycle policy for rolling when the index is bigger than 10GB, but I don't know how define the daily ro…

---

## [Elasticsearch Highlighting: Return all matches](https://discuss.elastic.co/t/elasticsearch-highlighting-return-all-matches/193117)

<div class="topic-metadata">

**Author:** [@jriedl](https://discuss.elastic.co/u/jriedl)\
**Replies:** 0\
**Last updated:** [July 31, 2019, 12:40pm UTC](https://discuss.elastic.co/t/elasticsearch-highlighting-return-all-matches/193117 "2019-07-31T12:40:37Z")

</div>

We are aiming to provide a fulltext search that returns highlighted snippets. In some contexts it is necessary to obtain all matches within a text document (which is so far saved in a single field). However, increasing t…

---

## [Filter on empty terms](https://discuss.elastic.co/t/filter-on-empty-terms/193116)

<div class="topic-metadata">

**Author:** [@Enzo\_RC](https://discuss.elastic.co/u/Enzo_RC)\
**Replies:** 0\
**Last updated:** [July 31, 2019, 12:34pm UTC](https://discuss.elastic.co/t/filter-on-empty-terms/193116 "2019-07-31T12:34:01Z")

</div>

Hello, I'm building an app with Dash, i created a checklist, that returns a list of terms. I use that list to filter on my fields. But when there is no filter i don't know how to inform my query to not filter on anythin…

---

## [How to secure ELK stack](https://discuss.elastic.co/t/how-to-secure-elk-stack/193112)

<div class="topic-metadata">

**Author:** [@kjh](https://discuss.elastic.co/u/kjh)\
**Replies:** 1\
**Last updated:** [July 31, 2019, 12:34pm UTC](https://discuss.elastic.co/t/how-to-secure-elk-stack/193112 "2019-07-31T12:34:14Z")

</div>

Can anyone pleaSe provide some idea hownwe can secure our ELK stack for eg writing curl delete command anyone can delete our index so i wanted to know how we can secure our ELK stack. Thanks in Advance

---

## [Unassigned Shards, what to do about it](https://discuss.elastic.co/t/unassigned-shards-what-to-do-about-it/192892)

<div class="topic-metadata">

**Author:** [@Moritz\_Kiesewetter](https://discuss.elastic.co/u/Moritz_Kiesewetter)\
**Replies:** 12\
**Last updated:** [July 31, 2019, 11:22am UTC](https://discuss.elastic.co/t/unassigned-shards-what-to-do-about-it/192892 "2019-07-31T11:22:58Z")

</div>

Hello Guys, first off, our Cluster: Master (Kibana) -8GB -Appache Web Server -Does not filter/query Workernode#01/#02 -32GB Ram each -No Kibana Soo my cluster is running about fine, there's just this thing that …

---

## [How to filter out certain Log-Types in old Indexes](https://discuss.elastic.co/t/how-to-filter-out-certain-log-types-in-old-indexes/193115)

<div class="topic-metadata">

**Author:** [@Moritz\_Kiesewetter](https://discuss.elastic.co/u/Moritz_Kiesewetter)\
**Replies:** 0\
**Last updated:** [July 31, 2019, 12:28pm UTC](https://discuss.elastic.co/t/how-to-filter-out-certain-log-types-in-old-indexes/193115 "2019-07-31T12:28:16Z")

</div>

Hello Guys, so i've got a little problem on my hands. I've got an ES-Cluster running just about fine now. Except for DiskSpace. That's (in my opinion) the result of the Month June because in June our huge VM-WareCluste…

---

## [Date fields from CSV are coming as String data type in kibana 7.2 instead of Date data type](https://discuss.elastic.co/t/date-fields-from-csv-are-coming-as-string-data-type-in-kibana-7-2-instead-of-date-data-type/193113)

<div class="topic-metadata">

**Author:** [@vinay.rao](https://discuss.elastic.co/u/vinay.rao)\
**Replies:** 0\
**Last updated:** [July 31, 2019, 12:07pm UTC](https://discuss.elastic.co/t/date-fields-from-csv-are-coming-as-string-data-type-in-kibana-7-2-instead-of-date-data-type/193113 "2019-07-31T12:07:22Z")

</div>

Dear All, Am loading CSV file into logstash, Date field is loading as String data type in kibana, which i need to be in Date data type. Please help me to identify where am lagging to achieve the same. Please find the at…

---

## [Bucket selector in sub aggregation or cardinality aggregation](https://discuss.elastic.co/t/bucket-selector-in-sub-aggregation-or-cardinality-aggregation/193060)

<div class="topic-metadata">

**Author:** [@Vladpov](https://discuss.elastic.co/u/Vladpov)\
**Replies:** 5\
**Last updated:** [July 31, 2019, 12:00pm UTC](https://discuss.elastic.co/t/bucket-selector-in-sub-aggregation-or-cardinality-aggregation/193060 "2019-07-31T12:00:58Z")

</div>

Hi guys I have this query GET /my\_index3/\_search { "size": 0, "aggs": { "num1": { "terms": { "field": "num1.keyword", "order" : { "\_count" : "desc" } }, "aggs": { "count…

---

## [The same problem with you about it](https://discuss.elastic.co/t/the-same-problem-with-you-about-it/191572)

<div class="topic-metadata">

**Author:** [@anon20829737](https://discuss.elastic.co/u/anon20829737)\
**Replies:** 5\
**Last updated:** [July 26, 2019, 7:37am UTC](https://discuss.elastic.co/t/the-same-problem-with-you-about-it/191572 "2019-07-26T07:37:23Z")

</div>

Nothing to type

---

## [Elasticsearch query problem](https://discuss.elastic.co/t/elasticsearch-query-problem/192383)

<div class="topic-metadata">

**Author:** [@Vladpov](https://discuss.elastic.co/u/Vladpov)\
**Replies:** 9\
**Last updated:** [July 31, 2019, 11:17am UTC](https://discuss.elastic.co/t/elasticsearch-query-problem/192383 "2019-07-31T11:17:12Z")

</div>

Hi guys! I've got a problem with definition of query in elasticsearch. I've got two types of messages: Jul 23 09:24:16 mmr mmr-core\[5147\]: Aweg3AOMTs\_1563866656876839.mt processMTMessage() #12798 realtime: 5.684 ms …

---

## [Create Index and Mappings](https://discuss.elastic.co/t/create-index-and-mappings/193096)

<div class="topic-metadata">

**Author:** [@Naveedyousaf03](https://discuss.elastic.co/u/Naveedyousaf03)\
**Replies:** 0\
**Last updated:** [July 31, 2019, 10:55am UTC](https://discuss.elastic.co/t/create-index-and-mappings/193096 "2019-07-31T10:55:19Z")

</div>

Hi all, I am running elasticsearch dot net Version 7.1.0 and using elastic search 6.3.0. I want to know if index exist or not. If it exist then index data otherwise create the index with mappings but i am unable to do s…

---

## [Difficulties with aggregations](https://discuss.elastic.co/t/difficulties-with-aggregations/193089)

<div class="topic-metadata">

**Author:** [@Louis-Clement](https://discuss.elastic.co/u/Louis-Clement)\
**Replies:** 0\
**Last updated:** [July 31, 2019, 10:04am UTC](https://discuss.elastic.co/t/difficulties-with-aggregations/193089 "2019-07-31T10:04:33Z")

</div>

Hi! I'm a beginner in Elasticsearch queries and I have difficulties with aggregations. To explain easily my problem, I will work with an example: Imagine I have planted tomatoes and carrots in several fields. So each…

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

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