码迷,mamicode.com
首页 > 其他好文 > 详细

ELK安装

时间:2016-09-06 23:25:29      阅读:214      评论:0      收藏:0      [点我收藏+]

标签:elk

wget https://download.elastic.co/elasticsearch/release/org/elasticsearch/distribution/tar/elasticsearch/2.4.0/elasticsearch-2.4.0.tar.gz

wget https://download.elastic.co/logstash/logstash/logstash-2.4.0.tar.gz

wget https://download.elastic.co/kibana/kibana/kibana-4.6.0-linux-x86_64.tar.gz


tar zxvf elasticsearch-2.4.0.tar.gz

tar zxvf kibana-4.6.0-linux-x86_64.tar.gz

tar zxvf logstash-2.4.0.tar.gz


mv elasticsearch-2.4.0 elasticsearch

mv kibana-4.6.0-linux-x86_64 kibana

mv logstash-2.4.0 logstash


groupadd elasticsearch

useradd -g elasticsearch -d /usr/local/elasticsearch elasticsearch

mv elasticsearch/* /usr/local/elasticsearch

chown -R elasticsearch.elasticsearch /usr/local/elasticsearch

chown -R elasticsearch.elasticsearch /data/elasticsearch


./bin/plugin install mobz/elasticsearch-head


vi config/elasticsearch.yml

cluster.name: niudingfeng

node.name: node-1

path.data: /data/elasticsearch/data

path.logs: /data/elasticsearch/logs

network.host: 10.10.16.193

http.port: 9200


启动:./bin/elasticsearch &


查看地址:http://10.10.16.194:9200/_plugin/head/   http://10.10.16.194:9200/


vim config/kibana.yml


server.port: 5601

server.host: "10.10.16.194"

elasticsearch.url: "http://10.10.16.194:9200"

kibana.index: ".kibana"


启动:./bin/kibana &

查看:

http://10.10.16.194:5601/



nohup /root/logstash/bin/logstash agent -f /root/logstash_agent.conf &

input {

  file {

    type => "logtest"

    path => ["/root/access_log"]

  }

}


output {

  elasticsearch {

    action => "index"

    hosts => "10.10.16.194:9200"

    index  => "applog"

  }

}


本文出自 “我的运维时光” 博客,请务必保留此出处http://aaronsa.blog.51cto.com/5157083/1846947

ELK安装

标签:elk

原文地址:http://aaronsa.blog.51cto.com/5157083/1846947

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!