elasticsearch centos 安装记录 及 启动手记 正式服务器 39

环境安装

elasticsearch 安装

./elasticsearch-plugin remove x-pack
./elasticsearch-plugin remove analysis-ik
./elasticsearch-plugin install https://github.com/medcl/elasticsearch-analysis-ik/releases/download/v6.1.1/elasticsearch-analysis-ik-6.1.1.zip

./elasticsearch-plugin install https://github.com/medcl/elasticsearch-analysis-ik/releases/download/v6.5.1/elasticsearch-analysis-ik-6.5.1.zip

[https://artifacts.elastic.co/downloads/kibana-plugins/x-pack/x-pack-6.1.1.zip]x-pack-6.1.1.zip](https://artifacts.elastic.co/downloads/kibana-plugins/x-pack/x-pack-6.1.1.zip]x-pack-6.1.1.zip "https://artifacts.elastic.co/downloads/kibana-plugins/x-pack/x-pack-6.1.1.zip]x-pack-6.1.1.zip")

[url=https://www.elastic.co/guide/en/elasticsearch/reference/6.1/installing-xpack-es.html]installing-xpack-es.html[/url]

./elasticsearch-plugin install file:///run/media/linjinyu/25f7980e-9a12-41e0-a299-d7fb5d1bf7e2/__elasticsearch__/x-pack-6.1.1.zip

logstash 安装

#root ./logstash-plugin install logstash-input-jdbc
#root ./logstash-plugin install logstash-output-elasticsearch

kibana 安装

./kibana-plugin install x-pack

[url=http://club.400-lighting.com/forum.php?mod=viewthread&tid=1332]Elasticsearch(一)开启外网访问[/url]

开放端口

root vi /etc/sysconfig/iptables

-A INPUT -p tcp -m state --state NEW -m tcp --dport 9200 -j ACCEPT
-A INPUT -p tcp -m state --state NEW -m tcp --dport 9300 -j ACCEPT

生效方法1

#root service iptables restart

方法2

[root@izwz93p6s96mh2av2ty5khz /]# service iptables restart
Redirecting to /bin/systemctl restart  iptables.service

启动问题杂锦

 #root vi /etc/security/limits.conf 
 #root sysctl -p

启动前题

elasticsearch 不能用root来运行的

建立
ac:elsearch
pw:elasticsearch

改密码
root 下
passwd elsearch

启动命令

其中-d表示后台启动

#elsearch ./elasticsearch -d
chown -R elsearch.elsearch elasticsearch-6.1.1
#root|elsearch ./logstash -f ./config/conf/ims_superdesk_shop_goods_v20180411.conf

#root|elsearch ./logstash -f ./config/conf/ims_superdesk_shop_goods_v20180413.conf

./logstash -f ./config/conf/ims_superdesk_shop_goods_v20180511.conf

关闭命令

好使

#elsearch pkill -f elasticsearch

待测试,不成功,到底那错了呢?

kill -9  $(netstat -nlpt | grep 9300 | cut -d ' ' -f 58 | cut -d '/' -f 1)

测试

本地测试

curl -GET 'http://localhost:9200'

请先后发表评论
  • 最新评论
  • 总共0条评论