mkdir -p ~/.curator/
vim ~/.curator/curator.yml
---
# Remember, leave a key empty if there is no value. None will be a string,
# not a Python "NoneType"
client:
hosts:
- 172.20.11.32 《== 集群节点IP地址,可以写多个
port: 9200 《== datanode 接口
url_prefix:
use_ssl: False
certificate:
client_cert:
client_key:
ssl_no_validate: False
http_auth:
timeout: 30
master_only: False
logging:
loglevel: INFO 《== 日志级别
logfile: 《== 输出日志到文件
logformat: default
blacklist: ['elasticsearch', 'urllib3'] 重要选项介绍
loglevel 支持 :
CRITICAL will only display critical messages.
ERROR will only display error and critical messages.
WARNING will display error, warning, and critical messages.
INFO will display informational, error, warning, and critical messages.
DEBUG will display debug messages, in addition to all of the above.
logfile 支持:
default, json, logstash 或者留空;
blacklist 支持:
那些关键字开头索引日志不输出,默认即可。 ACTION_FILE.YML 介绍
Alias
Allocation
Close
Cluster Routing
Create Index
Delete Indices
Delete Snapshots
forceMerge
Index Settings
Open
Reindex
Replicas
Restore
Rollover
Shrink
Snapshot
option: 选项 ,filter:过滤条件,哪些index需要执行action,详细参考官网;
https://www.elastic.co/guide/en/elasticsearch/client/curator/current/actions.html