bin/elasticsearch-plugin install x-pack --batch
也可以直接下载模块
bin/elasticsearch-plugin install file://usr/local/src/x-pack.5.1.zip --batch
bin/kibana-plugin install x-pack --batch
xpack.security.enabled:(true/false) 是否开启安全验证
xpack.monitoring.enabled 是否开启监控
xpack.graph.enabled 是否开启图形
xpack.watcher.enabled 是否开启watcher 仅仅es配置
xpack.reporting.enabled 是否开启报表仅仅kibana配置
在ES 5.4版本参数
xpack.security.enabled: true
xpack.monitoring.enabled: false
xpack.graph.enabled: false
xpack.watcher.enabled: false
xpack.reporting.enabled: false
user:elastic
password: changeme
修改密码
curl -XPUT 'localhost:9200/_xpack/security/user/elastic/_password?pretty' -d' { "password": "elasticpassword" }'
curl -XPUT 'localhost:9200/_xpack/security/user/kibana/_password?pretty' -d'
{
"password": "kibanapassword"
}'
curl -XPOST 'localhost:9200/_xpack/security/user/jacknich?pretty' -d'
{
"password" : "j@rV1s",
"roles" : [ "admin", "other_role1" ],
"full_name" : "Jack Nicholson",
"email" : "jacknich@example.com",
"metadata" : {
"intelligence" : 7
},
"enabled": true
}'
curl -XDELETE 'localhost:9200/_xpack/security/user/jacknich?pretty'
原文地址:http://blog.51cto.com/nginxs/2083985