0

我们已经从AWS Elasticsearch 2.3迁移到5.1,并发现我们旧的策展人3命令不再用于删除超过30天的索引。我们这工作旧的命令如下所示:带有Curator的AWS Elasticsearch 5.1 4.2.6 - 删除索引不起作用?

00 00 * * 1 /bin/curator --host elasticsearch.production.domain.aws --port 80 delete indices --older-than 30 --time-unit days --timestring %Y.%m.%d --exclude .kibana 

移动馆长4.2.6被要求支持ES 5.1然而,使用提供from the elasticsearch page的例子时,我们发现我们收到的错误:

2017-02-15 11:46:18,874 INFO  Preparing Action ID: 1, "delete_indices" 
2017-02-15 11:46:18,884 INFO  Trying Action ID: 1, "delete_indices": Delete indices older than 45 days (based on index name), for logstash- prefixed indices. Ignore the error if the filter does not result in an actionable list of indices (ignore_empty_list) and exit cleanly. 
2017-02-15 11:46:18,897 ERROR  Failed to complete action: delete_indices. <class 'KeyError'>: 'settings' 

其他人在迁移后使用该配置获得成功吗?

我单独定义的curator.yaml配置我相信这是正确的:

client: 
    hosts: 
    - elasticsearch.production.domain.aws 
    port: 80 
    url_prefix: 
    use_ssl: False 
    certificate: 
    client_cert: 
    client_key: 
    ssl_no_validate: False 
    http_auth: 
    timeout: 30 
    master_only: False 
+0

我们是否也可以看到curator.yaml? –

+0

已更新curator.yml文件 –

回答

1

TL; DR: AWS ES仍然不支持必要的API调用(当然,他们这样做,但它不会返回必要的数据),Curator可以使用它。

虽然看起来AWS ES已经添加了必要的/_cluster/state端点(这就是为什么策展人4不支持AWS ES 2.3),但他们似乎已经省略了该端点的一些必要数据(这是您的一部分得到<class 'KeyError'>: 'settings'settings子对象的JSON响应丢失,所以策展人无法完成其任务

有已经在策展人这个开放式问题:。https://github.com/elastic/curator/issues/880,虽然我不觉得有什么,策展人可以做以解决此问题

+0

干杯untergeek。作为临时措施,我们将针对比X天更早的所有索引运行HTTP DELETE。 –