Getting error index.max_inner_result_window during rolling upgrade of ES from 5.6.10 to 6.8.10

593 views Asked by At

I have 2 data nodes and 3 master nodes in an ES cluster. I was doing a rolling upgrade as ES suggested moving from 5.6.10 to 6.8.10.

As there should be zero downtime, I was testing that and getting one error.

I have upgraded the 1 data node and do basic search testing. It is working fine. When I have upgraded 2nd node search is breaking with the below Error.

java.lang.IllegalArgumentException: Top hits result window is too large, the top hits aggregator [top]'s from + size must be less than or equal to: [100] but was [999]. This limit can be set by changing the [index.max_inner_result_window] index level setting.

index.max_inner_result_window -- This property was introduced in the 6.X version, and the master node is still on 5.6.10. So what will be the solution with 0 downtimes?

Note: My indexing is stopped completely. My 2 data nodes are now on 6.8.10 and master nodes are on 5.6.

Thanks

1

There are 1 answers

0
Rodrigo Soares On

1 - Change the parameter on current indexes:

curl -X PUT "http://localhost:9200/_all/_settings?pretty" -H 'Content-Type: application/json' -d'
{
  "index.max_inner_result_window": "2147483647"
}
'

2 - Create a template to further indexes:

curl -X PUT "http://localhost:9200/_index_template/template_max_inner_result?pretty" -H 'Content-Type: application/json' -d'
{
  "index_patterns": ["*"],
  "template": {
    "settings": {
      "index":{
        "max_inner_result_window": 2147483647
      }
    }
  }
}
'