您当前的位置: 首页 >  童心同萌 linux

Linux安装ES最新版

童心同萌 发布时间:2022-09-08 14:24:37 ,浏览量:4

链接:https://pan.baidu.com/s/16SOoN7ZveFu1ly9B2wudoA?pwd=8fm7

  1.  知识准备https://blog.csdn.net/tongxin_tongmeng/article/details/126342599

  2.  下载、解压ES8
  3. ES8上传Linux
  4. ES8运行环境(☆☆☆☆☆)
    1.防火墙打开端口权限
    firewall-cmd --zone=public --add-port=9200/tcp --permanent
    firewall-cmd --reload
    
    2.编辑/etc/security/limits.conf
    *          soft    nofile     65536
    *          hard    nofile     65536
    
    3.编辑/etc/security/limits.d/20-nproc.conf
    *          soft    nofile     65536
    *          hard    nofile     65536
    *          hard    nproc      4096
    
    4.编辑/etc/sysctl.conf
    vm.max_map_count=655360
    重新加载:sysctl -p
    
    注意:重启虚拟机确保修改生效

  5. ES8环境变量
    编辑/etc/profile添加elasticsearch环境变量
    export ES_HOME=/home/elasticsearch/elasticsearch-8.4.1
    export ES_JAVA_HOME=/home/elasticsearch/elasticsearch-8.4.1/jdk
    export PATH=$PATH:$ES_HOME/bin/
    环境变量立刻生效:source /etc/profile
    判断环境变量生效:elasticsearch -d
  6. 创建新用户
    添加用户:useradd es8
    设置密码:passwd es8
    用户授权:chown -R es8:es8 /home/elasticsearch
    切换用户:su es8

  7. ES服务启动、查看、关闭
    启动ES服务:elasticsearch -d
    查看ES服务:ps -ef | grep -i elasticsearch
    关闭ES服务:kill -9 进程号
  8. ES服务访问
  9.  ES8关闭密码认证
    编辑/home/elasticsearch/elasticsearch-8.4.1/config/elasticsearch.yml
    xpack.security.enabled: false
    xpack.security.enrollment.enabled: false
    xpack.security.http.ssl:
      enabled: false
      keystore.path: certs/http.p12
关注
打赏
1688896170
查看更多评论

童心同萌

暂无认证

  • 4浏览

    0关注

    87博文

    0收益

  • 0浏览

    0点赞

    0打赏

    0留言

私信
关注
热门博文
立即登录/注册

微信扫码登录

0.0540s