环境:
推荐虚拟机内存2G
elasticsearch安装包:wget https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.3.0-x86_64.rpm
或yum源
vim /etc/yum.repo.d/ELK.repo
[ELK]
name=ELK-Elasticstack
baseurl=https://mirrors.tuna.tsinghua.edu.cn/elasticstack/yum/elastic-6.x/
gpgcheck=0
enabled=1
jdk11:
yum install elasticsearch -y
配置文件:/etc/elasticsearch.yml
[root@exam01 src]# grep "^[a-z]" /etc/elasticsearch/elasticsearch.yml
cluster.name: oldboy
node.name: linux-node1
path.data: /data/es-data
path.logs: /var/log/elasticsearch
network.host: 0.0.0.0
http.port: 9200
discovery.seed_hosts: ["10.10.10.25", "10.10.10.26"]
cluster.initial_master_nodes: ["linux-node1"]
启动访问10.10.10.25:9200
{
"name" : "linux-node1",
"cluster_name" : "oldboy",
"cluster_uuid" : "zTpe4VW0Q8WahK_XxTvo7w",
"version" : {
"number" : "7.3.0",
"build_flavor" : "default",
"build_type" : "rpm",
"build_hash" : "de777fa",
"build_date" : "2019-07-24T18:30:11.767338Z",
"build_snapshot" : false,
"lucene_version" : "8.1.0",
"minimum_wire_compatibility_version" : "6.8.0",
"minimum_index_compatibility_version" : "6.0.0-beta1"
},
"tagline" : "You Know, for Search"
}
vim /etc/elasticsearch/jvm.options
-Xms1g #指定占用内存大小,两个数字要一致 都是1g
-Xmx1g
安装kibana
配置文件/etc/kibana.yml
[root@linux-node1 bin]# grep ^[a-z] /etc/kibana/kibana.yml
server.port: 5601
server.host: "10.10.10.25"
server.name: "linux-node1"
elasticsearch.hosts: ["http://10.10.10.25:9200"]
kibana.index: ".kibana"
logging.dest: /data/log/kibana/kibana.log
i18n.locale: "zh-CN"