添砖加瓦:简述ELK部署
1、准备工作
ELK下载:https://www.elastic.co/downloads/
jdk version:1.8.0_162
2、环境搭建
ElasticSearch:
(1)不能使用root用户启动,需将elasticsearch文件夹放在执行用户目录下,否则会报错:“错误: 找不到或无法加载主类 org.elasticsearch.tools.launchers.JavaVersionChecker”
(2)插件安装:bin/elasticsearch-plugin install x-pack
(3)修改配置文件 vim config/elasticsearch.yml:
cluster.name: myapp
node.name: node0
path.data: /path/to/data
path.logs: /path/to/logs
network.host: 127.0.0.1(若要局域网访问,需要添加端口或直接关闭防火墙
service iptables stop
chkconfig iptables off(永久关闭)
)
http.port: 9200
bootstrap.system_call_filter: false(add)
xpack.security.enabled: false(取消用户登陆的验证)
注:尽量保持冒号前面没空格,后面一个空格,不要用tab键,否则会报错:“Exception in thread "main" 2017-11-10 06:29:49,106 main ERROR No log4j2 configuration file found. Using default configuration: logging only errors to the console. Set system property 'log4j2.debug' to show Log4j2 internal initialization logging.ElasticsearchParseException[malformed, expected settings to start with 'object', instead was [VALUE_STRING]]”
vim /etc/security/limits.d/90-nproc.conf
elasticsearch soft nproc 4096 # 针对 max number of threads
elasticsearch hard nproc 4096
elasticsearch soft nofile 65536 # 针对 max file descriptors (add)
elasticsearch hard nofile 65536
vim /etc/sysctl.conf
vm.max_map_count=262144 # 针对 max virtual memory areas(add) (sysctl -p 使生效)
Kiabna
(1)解压后,执行“./bin/kibana-plugin install x-pack”安装X-Pack
(2)修改配置文件kibana.yml
elasticsearch.url: "http://192.168.11.13:9200"
server.host: "192.168.11.13"
logstash
(1)解压后,执行“./bin/logstash-plugin install x-pack”安装X-Pack
(2)修改配置文件logstash.yml,添加如下
xpack.monitoring.enabled: true
xpack.monitoring.elasticsearch.url: ["http://192.168.11.13:9200"]([]中填写elasticsearch运行后能访问到的IP和端口)
(3)添加配置文件:logstash.conf
input {
file {
path => "/home/elsearch/error.log"
type => "error"
start_position => "beginning"
}
}
filter {
grok {
match => {"message" => "%{DATESTAMP:mytime}"}
}
}
output {
stdout {
codec => rubydebug { }
}
elasticsearch {
hosts => ["192.168.11.13:9200"]
index => "error-%{+YYYY.MM.dd}"
}
}
3、启动顺序
elsticsearch先启动,logstash和kiabna之后启动
添砖加瓦:简述ELK部署的更多相关文章
- 分布式实时日志分析解决方案ELK部署架构
一.概述 ELK 已经成为目前最流行的集中式日志解决方案,它主要是由Beats.Logstash.Elasticsearch.Kibana等组件组成,来共同完成实时日志的收集,存储,展示等一站式的解决 ...
- ELK 部署
文章转载: http://www.open-open.com/doc/view/df156a76a824402482d1d72cd3b61e38 http://www.open-open.com/li ...
- Filebeat+ELK部署文档
在日常运维工作中,对于系统和业务日志的处理尤为重要.今天,在这里分享一下自己部署的Filebeat+ELK开源实时日志分析平台的记录过程,有不对的地方还望指出. 简单介绍: 日志主要包括系统日志.应用 ...
- ELK部署与使用总结
前言 自己最近在负责elk的工作,在这里想写一个总结,把好多遇到的问题啥的,都写一下,也做个笔记, 目录 环境介绍 kafka,zookeeper安装 logstash安装 elasticsearch ...
- ELKStack入门篇(一)之ELK部署和使用
一.ELKStack简介 1.ELK介绍 中文指南:https://www.gitbook.com/book/chenryn/elk-stack-guide-cn/details ELK Stack包 ...
- centos7环境下ELK部署之elasticsearch
es部署:es只能用普通用户启动 博客园首发,转载请注明出处:https://www.cnblogs.com/tzxxh/p/9435318.html 一.环境准备: 安装jdk1.8.创建普通用户 ...
- filebeat + ELK 部署篇
ELK Stack Elasticsearch:分布式搜索和分析引擎,具有高可伸缩.高可靠和易管理等特点.基于 Apache Lucene 构建,能对大容量的数据进行接近实时的存储.搜索和分析操作.通 ...
- ELK部署配置使用记录
为什么要用ELK: 一般我们需要进行日志分析场景:直接在日志文件中 grep.awk 就可以获得自己想要的信息.但在规模较大的场景中,此方法效率低下,面临问题包括日志量太大如何归档.文本搜索太慢怎么办 ...
- ELK 部署文档
1. 前言 在日常运维工作中,对于系统和业务日志的处理尤为重要.尤其是分布式架构,每个服务都会有很多节点,如果要手工一个一个的去取日志,运维怕是要累死. 简单介绍: ELK 是 elasticsear ...
随机推荐
- 如何动态调用WebService
封装WBS类 using System; using System.Collections.Generic; using System.Linq; using System.Web; using Sy ...
- echart图表demo
<!DOCTYPE html><html><head> <title>echarts</title></head><scr ...
- 发生 Configuration system failed to initialize 错误的一个特例
一般情况下,.net 程序启动时发生 Configuration system failed to initialize 错误, 大都与 config 文件中 <configSections&g ...
- python学习笔记(25)-继承
#继承 class RobotOne: #第一代机器人 def __init__(self,year,name): self.year=year self.name=name def walking_ ...
- CodeForces 91B Queue (线段树,区间最值)
http://codeforces.com/problemset/problem/91/B B. Queue time limit per test: 2 seconds memory limit p ...
- vue实现动态绑定class--多个按钮点击一个有一个
<template> //v-for循环出来多个按钮,便于获取index <span v-for="(item,index) in list" : ...
- 让Spring不再难懂-mvc篇
spring mvc简介与运行原理 Spring的模型-视图-控制器(MVC)框架是围绕一个DispatcherServlet来设计的,这个Servlet会把请求分发给各个处理器,并支持可配置的处理器 ...
- python+locust性能测试-最简单的登录点击次数
from locust import HttpLocust,TaskSet,task import os class UserBehavior(TaskSet): @task def login(se ...
- Smarty使用-模版中编写js
在smarty模版中编写js使用literal标签, Literal 标签区域内的数据将被当作文本处理,此时模板将忽略其内部的所有字符信息. 该特性用于显示有可能包含大括号等字符信息的 javas ...
- Create Access Point on Archlinux
Create Access Point on Archlinux */--> Create Access Point on Archlinux 1 Solution Download creat ...