LoginSignup
5
6

More than 5 years have passed since last update.

Kibana の設定を Export Everything しても取得できない

Last updated at Posted at 2016-01-21

TL;DR

  • Kibana ver 4.3.0 だとバグッてて Export Everything が使えない。
  • index.max_result_window の設定値を変更すれば使えるようになる。

この問題は kibana v4.3.1 の Pull Request 5586 で修正されていた。
kibana 4.3.1 Release Notes

環境

  • CentOS 6.7
  • Elasticsearch ver 2.1.1
  • Kibana ver 4.3.0

現象

構築した Kibana の検索条件やダッシュボードの設定をバックアップしたり、そのまま他の環境の kibana にも適用したくて、settings > ObjectsExport Everything したけど何も起きない。

スクリーンショット_012116_122413_AM.jpg

原因

Kibana のログを見てみると下記エラーログが出ていた。
なにやら index.max_result_window って制限値が小さいんだけど、設定変更できるよって言ってる。

RemoteTransportException[[coesse-es-01][127.0.0.1:9300][indices:data/read/search[phase/query+fetch]]]; nested: QueryPhaseExecutionException[Result window is too large, from + size must be less than or equal to: [10000] but was [2147483647]. See the scroll api for a more efficient way to request large data sets. This limit can be set by changing the [index.max_result_window] index level parameter.];
Caused by: QueryPhaseExecutionException[Result window is too large, from + size must be less than or equal to: [10000] but was [2147483647]. See the scroll api for a more efficient way to request large data sets. This limit can be set by changing the [index.max_result_window] index level parameter.]

index.max_result_window って?

下記リンク先にちょっと書いてあった。

Search changes - from + size limits

max_result_window は、動的に変更可能なパラメータで、デフォルトはほぼ全てのクラスタで安全に使える 10,000 にしてるよ。高い値にしちゃうとヒープを大量に消費しちゃうからね、みたいな感じ。
from + size がどういう値なのかよく分からないけど…、設定名からして検索結果に応じたサイズなのだろう。

対処

本件は Issue になっていて、上記メッセージと同じく設定の変更を暫定対処としてコメントされていた。

Kibana 4.3 "Export Everything" exception · Issue #5524 · elastic/kibana

じゃあ、早速。

$ curl -X PUT localhost:9200/.kibana/_settings -d '{ "index": { "max_result_window": 2147483647 }}'
{"acknowledged":true}

改めて Export Everything してみたところ、以下の通り export.json として出力されるようになった。

スクリーンショット_012116_125111_AM.jpg

5
6
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
5
6