zoukankan      html  css  js  c++  java
  • Centos7使用Docker启动elasticsearch服务秒退

    首先查看docker启动日志

    docker logs -f 容器id
    

      

    查看报错信息

    OpenJDK 64-Bit Server VM warning: Option UseConcMarkSweepGC was deprecated in version 9.0 and will likely be removed in a future release.
    [2019-11-24T11:17:55,311][WARN ][o.e.c.l.LogConfigurator  ] [unknown] Some logging configurations have %marker but don't have %node_name. We will automatically add %node_name to the pattern to ease the migration for users who customize log4j2.properties but will stop this behavior in 7.0. You should manually replace `%node_name` with `[%node_name]%marker ` in these locations:
      /usr/share/elasticsearch/config/log4j2.properties
    [2019-11-24T11:18:02,295][INFO ][o.e.e.NodeEnvironment    ] [l6-XUOr] using [1] data paths, mounts [[/ (rootfs)]], net usable_space [11gb], net total_space [37.6gb], types [rootfs]
    [2019-11-24T11:18:02,296][INFO ][o.e.e.NodeEnvironment    ] [l6-XUOr] heap size [247.6mb], compressed ordinary object pointers [true]
    [2019-11-24T11:18:02,319][INFO ][o.e.n.Node               ] [l6-XUOr] node name derived from node ID [l6-XUOrfQuSDM1xQLV4irA]; set [node.name] to override
    [2019-11-24T11:18:02,319][INFO ][o.e.n.Node               ] [l6-XUOr] version[6.5.0], pid[1], build[default/tar/816e6f6/2018-11-09T18:58:36.352602Z], OS[Linux/3.10.0-1062.4.1.el7.x86_64/amd64], JVM[Oracle Corporation/OpenJDK 64-Bit Server VM/11.0.1/11.0.1+13]
    [2019-11-24T11:18:02,319][INFO ][o.e.n.Node               ] [l6-XUOr] JVM arguments [-Xms1g, -Xmx1g, -XX:+UseConcMarkSweepGC, -XX:CMSInitiatingOccupancyFraction=75, -XX:+UseCMSInitiatingOccupancyOnly, -XX:+AlwaysPreTouch, -Xss1m, -Djava.awt.headless=true, -Dfile.encoding=UTF-8, -Djna.nosys=true, -XX:-OmitStackTraceInFastThrow, -Dio.netty.noUnsafe=true, -Dio.netty.noKeySetOptimization=true, -Dio.netty.recycler.maxCapacityPerThread=0, -Dlog4j.shutdownHookEnabled=false, -Dlog4j2.disable.jmx=true, -Djava.io.tmpdir=/tmp/elasticsearch.IPIWmr7p, -XX:+HeapDumpOnOutOfMemoryError, -XX:HeapDumpPath=data, -XX:ErrorFile=logs/hs_err_pid%p.log, -Xlog:gc*,gc+age=trace,safepoint:file=logs/gc.log:utctime,pid,tags:filecount=32,filesize=64m, -Djava.locale.providers=COMPAT, -XX:UseAVX=2, -Des.cgroups.hierarchy.override=/, -Xms256m, -Xmx256m, -Des.path.home=/usr/share/elasticsearch, -Des.path.conf=/usr/share/elasticsearch/config, -Des.distribution.flavor=default, -Des.distribution.type=tar]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [aggs-matrix-stats]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [analysis-common]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [ingest-common]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [lang-expression]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [lang-mustache]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [lang-painless]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [mapper-extras]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [parent-join]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [percolator]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [rank-eval]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [reindex]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [repository-url]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [transport-netty4]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [tribe]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [x-pack-ccr]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [x-pack-core]
    [2019-11-24T11:18:12,063][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [x-pack-deprecation]
    [2019-11-24T11:18:12,064][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [x-pack-graph]
    [2019-11-24T11:18:12,064][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [x-pack-logstash]
    [2019-11-24T11:18:12,064][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [x-pack-ml]
    [2019-11-24T11:18:12,064][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [x-pack-monitoring]
    [2019-11-24T11:18:12,064][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [x-pack-rollup]
    [2019-11-24T11:18:12,064][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [x-pack-security]
    [2019-11-24T11:18:12,064][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [x-pack-sql]
    [2019-11-24T11:18:12,064][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [x-pack-upgrade]
    [2019-11-24T11:18:12,064][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded module [x-pack-watcher]
    [2019-11-24T11:18:12,064][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded plugin [ingest-geoip]
    [2019-11-24T11:18:12,065][INFO ][o.e.p.PluginsService     ] [l6-XUOr] loaded plugin [ingest-user-agent]
    [2019-11-24T11:18:32,588][INFO ][o.e.x.s.a.s.FileRolesStore] [l6-XUOr] parsed [0] roles from file [/usr/share/elasticsearch/config/roles.yml]
    [2019-11-24T11:18:34,749][INFO ][o.e.x.m.j.p.l.CppLogMessageHandler] [l6-XUOr] [controller/62] [Main.cc@109] controller (64 bit): Version 6.5.0 (Build 71882a589e5556) Copyright (c) 2018 Elasticsearch BV
    [2019-11-24T11:18:37,168][INFO ][o.e.d.DiscoveryModule    ] [l6-XUOr] using discovery type [zen] and host providers [settings]
    [2019-11-24T11:18:40,908][INFO ][o.e.n.Node               ] [l6-XUOr] initialized
    [2019-11-24T11:18:40,908][INFO ][o.e.n.Node               ] [l6-XUOr] starting ...
    [2019-11-24T11:18:41,448][INFO ][o.e.t.TransportService   ] [l6-XUOr] publish_address {172.17.0.2:9300}, bound_addresses {[::]:9300}
    [2019-11-24T11:18:41,488][INFO ][o.e.b.BootstrapChecks    ] [l6-XUOr] bound or publishing to a non-loopback address, enforcing bootstrap checks
    ERROR: [1] bootstrap checks failed
    [1]: max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]
    [2019-11-24T11:18:41,538][INFO ][o.e.n.Node               ] [l6-XUOr] stopping ...
    [2019-11-24T11:18:41,608][INFO ][o.e.n.Node               ] [l6-XUOr] stopped
    [2019-11-24T11:18:41,608][INFO ][o.e.n.Node               ] [l6-XUOr] closing ...
    [2019-11-24T11:18:41,619][INFO ][o.e.n.Node               ] [l6-XUOr] closed
    [2019-11-24T11:18:41,621][INFO ][o.e.x.m.j.p.NativeController] [l6-XUOr] Native controller process has stopped - no new native processes can be started
    OpenJDK 64-Bit Server VM warning: Option UseConcMarkSweepGC was deprecated in version 9.0 and will likely be removed in a future release.
    [2019-11-24T11:22:59,885][WARN ][o.e.c.l.LogConfigurator  ] [unknown] Some logging configurations have %marker but don't have %node_name. We will automatically add %node_name to the pattern to ease the migration for users who customize log4j2.properties but will stop this behavior in 7.0. You should manually replace `%node_name` with `[%node_name]%marker ` in these locations:
      /usr/share/elasticsearch/config/log4j2.properties
    

      

    修改配置文件

    vim /etc/sysctl.conf 
    

      

    添加下面配置:

    vm.max_map_count=655360
    

      

    然后重新启动容器

    docker start my_es(my_es为容器名称)
    

      

  • 相关阅读:
    原型链与继承
    js错误处理Try-catch和throw
    函数柯里化
    js函数节流
    事件委托
    innerHTML属性的内存和性能问题
    微信小程序左滑显示按钮demo
    this的作用
    前端工作面试经典问题(超级全)
    HTML5入门指南
  • 原文地址:https://www.cnblogs.com/pxblog/p/11923917.html
Copyright © 2011-2022 走看看