久しぶりに、
org.elasticsearch.indices.IndexClosedException: closed
対応した
過去 正常終了していた curl コマンドを 実行する
以前正常終了していたindex_closed_exception
が
% curl -XGET localhost:9200/festival/_search?pretty -d '{"query":{"match":{"name":"高槻"}}}}' { "error" : { "root_cause" : [ { "type" : "index_closed_exception", "reason" : "closed", "index_uuid" : "x_KUTOgwQ2utEoTKe-WcQw", "index" : "festival" } ], "type" : "index_closed_exception", "reason" : "closed", "index_uuid" : "x_KUTOgwQ2utEoTKe-WcQw", "index" : "festival" }, "status" : 403 }
そもそも Elasticsearch の index って 何だか 忘れてしまった。
以下に、MYSQLに<wbr>おける<wbr>databaseが<wbr>index
。
そういえばそうだった
Elasticsearchチュートリアル - 不可視点
いつ、
How to test working TTL documents in Elasticsearch — Makina Corpus
とりあえず、 open する
closeした
open は
% curl -XPOST 'localhost:9200/festival/_open' { "error": { "root_cause": [ { "type": "exception", "reason": "Failed to verify index [festival/x_KUTOgwQ2utEoTKe-WcQw]" } ], "type": "exception", "reason": "Failed to verify index [festival/x_KUTOgwQ2utEoTKe-WcQw]", "caused_by": { "type": "illegal_argument_exception", "reason": "Unknown tokenizer type [kuromoji_tokenizer] for [kuromoji]" } }, "status": 500 }
そういえば、
brew upgrade
をplugin の
% curl -X GET 'http://localhost:9200/_nodes/plugins?pretty' { "_nodes" : { "total" : 1, "successful" : 1, "failed" : 0 }, "cluster_name" : "elasticsearch_kensakurai", "nodes" : { "JlcSImkkRKu0kttzskrjxQ" : { "name" : "JlcSImk", "transport_address" : "10.0.1.11:9300", "host" : "10.0.1.11", "ip" : "10.0.1.11", "version" : "5.5.2", "build_hash" : "b2f0c09", "roles" : [ "master", "data", "ingest" ], "plugins" : [ ], "modules" : [ { "name" : "aggs-matrix-stats", "version" : "5.5.2", "description" : "Adds aggregations whose input are a list of numeric fields and output includes a matrix.", "classname" : "org.elasticsearch.search.aggregations.matrix.MatrixAggregationPlugin", "has_native_controller" : false }, { "name" : "ingest-common", "version" : "5.5.2", "description" : "Module for ingest processors that do not require additional security permissions or have large dependencies and resources", "classname" : "org.elasticsearch.ingest.common.IngestCommonPlugin", "has_native_controller" : false }, { "name" : "lang-expression", "version" : "5.5.2", "description" : "Lucene expressions integration for Elasticsearch", "classname" : "org.elasticsearch.script.expression.ExpressionPlugin", "has_native_controller" : false }, { "name" : "lang-groovy", "version" : "5.5.2", "description" : "Groovy scripting integration for Elasticsearch", "classname" : "org.elasticsearch.script.groovy.GroovyPlugin", "has_native_controller" : false }, { "name" : "lang-mustache", "version" : "5.5.2", "description" : "Mustache scripting integration for Elasticsearch", "classname" : "org.elasticsearch.script.mustache.MustachePlugin", "has_native_controller" : false }, { "name" : "lang-painless", "version" : "5.5.2", "description" : "An easy, safe and fast scripting language for Elasticsearch", "classname" : "org.elasticsearch.painless.PainlessPlugin", "has_native_controller" : false }, { "name" : "parent-join", "version" : "5.5.2", "description" : "This module adds the support parent-child queries and aggregations", "classname" : "org.elasticsearch.join.ParentJoinPlugin", "has_native_controller" : false }, { "name" : "percolator", "version" : "5.5.2", "description" : "Percolator module adds capability to index queries and query these queries by specifying documents", "classname" : "org.elasticsearch.percolator.PercolatorPlugin", "has_native_controller" : false }, { "name" : "reindex", "version" : "5.5.2", "description" : "The Reindex module adds APIs to reindex from one index to another or update documents in place.", "classname" : "org.elasticsearch.index.reindex.ReindexPlugin", "has_native_controller" : false }, { "name" : "transport-netty3", "version" : "5.5.2", "description" : "Netty 3 based transport implementation", "classname" : "org.elasticsearch.transport.Netty3Plugin", "has_native_controller" : false }, { "name" : "transport-netty4", "version" : "5.5.2", "description" : "Netty 4 based transport implementation", "classname" : "org.elasticsearch.transport.Netty4Plugin", "has_native_controller" : false } ] } } }
kuromoji plugin の インストール
kuromoji plugin を
sudo elasticsearch-plugin install analysis-kuromoji -> Downloading analysis-kuromoji from elastic [=================================================] 100% -> Installed analysis-kuromoji
% curl -X GET 'http://localhost:9200/_nodes/plugins?pretty' { "_nodes" : { "total" : 1, "successful" : 1, "failed" : 0 }, "cluster_name" : "elasticsearch_kensakurai", "nodes" : { "JlcSImkkRKu0kttzskrjxQ" : { "name" : "JlcSImk", "transport_address" : "10.0.1.11:9300", "host" : "10.0.1.11", "ip" : "10.0.1.11", "version" : "5.5.2", "build_hash" : "b2f0c09", "roles" : [ "master", "data", "ingest" ], "plugins" : [ { "name" : "analysis-kuromoji", "version" : "5.5.2", "description" : "The Japanese (kuromoji) Analysis plugin integrates Lucene kuromoji analysis module into elasticsearch.", "classname" : "org.elasticsearch.plugin.analysis.kuromoji.AnalysisKuromojiPlugin", "has_native_controller" : false } ], "modules" : [ { "name" : "aggs-matrix-stats", "version" : "5.5.2", "description" : "Adds aggregations whose input are a list of numeric fields and output includes a matrix.", "classname" : "org.elasticsearch.search.aggregations.matrix.MatrixAggregationPlugin", "has_native_controller" : false }, { "name" : "ingest-common", "version" : "5.5.2", "description" : "Module for ingest processors that do not require additional security permissions or have large dependencies and resources", "classname" : "org.elasticsearch.ingest.common.IngestCommonPlugin", "has_native_controller" : false }, { "name" : "lang-expression", "version" : "5.5.2", "description" : "Lucene expressions integration for Elasticsearch", "classname" : "org.elasticsearch.script.expression.ExpressionPlugin", "has_native_controller" : false }, { "name" : "lang-groovy", "version" : "5.5.2", "description" : "Groovy scripting integration for Elasticsearch", "classname" : "org.elasticsearch.script.groovy.GroovyPlugin", "has_native_controller" : false }, { "name" : "lang-mustache", "version" : "5.5.2", "description" : "Mustache scripting integration for Elasticsearch", "classname" : "org.elasticsearch.script.mustache.MustachePlugin", "has_native_controller" : false }, { "name" : "lang-painless", "version" : "5.5.2", "description" : "An easy, safe and fast scripting language for Elasticsearch", "classname" : "org.elasticsearch.painless.PainlessPlugin", "has_native_controller" : false }, { "name" : "parent-join", "version" : "5.5.2", "description" : "This module adds the support parent-child queries and aggregations", "classname" : "org.elasticsearch.join.ParentJoinPlugin", "has_native_controller" : false }, { "name" : "percolator", "version" : "5.5.2", "description" : "Percolator module adds capability to index queries and query these queries by specifying documents", "classname" : "org.elasticsearch.percolator.PercolatorPlugin", "has_native_controller" : false }, { "name" : "reindex", "version" : "5.5.2", "description" : "The Reindex module adds APIs to reindex from one index to another or update documents in place.", "classname" : "org.elasticsearch.index.reindex.ReindexPlugin", "has_native_controller" : false }, { "name" : "transport-netty3", "version" : "5.5.2", "description" : "Netty 3 based transport implementation", "classname" : "org.elasticsearch.transport.Netty3Plugin", "has_native_controller" : false }, { "name" : "transport-netty4", "version" : "5.5.2", "description" : "Netty 4 based transport implementation", "classname" : "org.elasticsearch.transport.Netty4Plugin", "has_native_controller" : false } ] } } }
再度 index を open する
% curl -XPOST 'localhost:9200/festival/_open' {"acknowledged":true}%
brew upgrade
を
以上です。
コメント