Qianlitp / WatchAD

AD Security Intrusion Detection System
GNU General Public License v3.0
1.29k stars 295 forks source link

elasticsearch 版本问题,导致docker-compose up 部署失败 #15

Closed liode1s closed 4 years ago

liode1s commented 4 years ago
"docker-compose.yaml" 61L, 1395C written                                                                                                                                                                                            
[2019-12-11T06:31:27,642][INFO ][o.e.n.Node               ] version[5.2.1], pid[1], build[db0d481/2017-02-09T22:05:32.386Z], OS[Linux/4.15.0-65-generic/amd64], JVM[Oracle Corporation/OpenJDK 64-Bit Server VM/1.8.0_121/25.121-b13]
[2019-12-11T06:31:28,434][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [aggs-matrix-stats]
[2019-12-11T06:31:28,434][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [ingest-common]
[2019-12-11T06:31:28,434][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [lang-expression]
[2019-12-11T06:31:28,434][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [lang-groovy]
[2019-12-11T06:31:28,434][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [lang-mustache]
[2019-12-11T06:31:28,435][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [lang-painless]
[2019-12-11T06:31:28,435][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [percolator]
[2019-12-11T06:31:28,435][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [reindex]
[2019-12-11T06:31:28,435][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [transport-netty3]
[2019-12-11T06:31:28,435][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [transport-netty4]
[2019-12-11T06:31:28,435][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] no plugins loaded
[2019-12-11T06:31:28,577][WARN ][o.e.d.s.g.GroovyScriptEngineService] [groovy] scripts are deprecated, use [painless] scripts instead
[2019-12-11T06:31:29,016][WARN ][o.e.b.ElasticsearchUncaughtExceptionHandler] [] uncaught exception in thread [main]
org.elasticsearch.bootstrap.StartupException: java.lang.IllegalStateException: No match found
        at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:125) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:112) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.cli.SettingCommand.execute(SettingCommand.java:54) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:122) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.cli.Command.main(Command.java:88) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:89) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:82) ~[elasticsearch-5.2.1.jar:5.2.1]
Caused by: java.lang.IllegalStateException: No match found
        at java.util.regex.Matcher.group(Matcher.java:536) ~[?:1.8.0_121]
        at org.elasticsearch.monitor.os.OsProbe.getControlGroups(OsProbe.java:216) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.monitor.os.OsProbe.getCgroup(OsProbe.java:414) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.monitor.os.OsProbe.osStats(OsProbe.java:466) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.monitor.os.OsService.<init>(OsService.java:45) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.monitor.MonitorService.<init>(MonitorService.java:45) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.node.Node.<init>(Node.java:345) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.node.Node.<init>(Node.java:232) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.bootstrap.Bootstrap$6.<init>(Bootstrap.java:241) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:241) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:333) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:121) ~[elasticsearch-5.2.1.jar:5.2.1]
        ... 6 more
[2019-12-11T06:32:31,344][INFO ][o.e.n.Node               ] [] initializing ...
[2019-12-11T06:32:31,410][INFO ][o.e.e.NodeEnvironment    ] [tJrR6Ce] using [1] data paths, mounts [[/usr/share/elasticsearch/data (/dev/sda2)]], net usable_space [266.1gb], net total_space [294.2gb], spins? [possibly], types [ext4]
[2019-12-11T06:32:31,410][INFO ][o.e.e.NodeEnvironment    ] [tJrR6Ce] heap size [494.9mb], compressed ordinary object pointers [true]
[2019-12-11T06:32:31,412][INFO ][o.e.n.Node               ] node name [tJrR6Ce] derived from node ID [tJrR6CeuT-i3TNaGoxZrTg]; set [node.name] to override
[2019-12-11T06:32:31,414][INFO ][o.e.n.Node               ] version[5.2.1], pid[1], build[db0d481/2017-02-09T22:05:32.386Z], OS[Linux/4.15.0-65-generic/amd64], JVM[Oracle Corporation/OpenJDK 64-Bit Server VM/1.8.0_121/25.121-b13]
[2019-12-11T06:32:32,236][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [aggs-matrix-stats]
[2019-12-11T06:32:32,237][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [ingest-common]
[2019-12-11T06:32:32,237][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [lang-expression]
[2019-12-11T06:32:32,237][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [lang-groovy]
[2019-12-11T06:32:32,237][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [lang-mustache]
[2019-12-11T06:32:32,237][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [lang-painless]
[2019-12-11T06:32:32,237][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [percolator]
[2019-12-11T06:32:32,237][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [reindex]
[2019-12-11T06:32:32,237][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [transport-netty3]
[2019-12-11T06:32:32,237][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] loaded module [transport-netty4]
[2019-12-11T06:32:32,238][INFO ][o.e.p.PluginsService     ] [tJrR6Ce] no plugins loaded
[2019-12-11T06:32:32,380][WARN ][o.e.d.s.g.GroovyScriptEngineService] [groovy] scripts are deprecated, use [painless] scripts instead
[2019-12-11T06:32:32,809][WARN ][o.e.b.ElasticsearchUncaughtExceptionHandler] [] uncaught exception in thread [main]
org.elasticsearch.bootstrap.StartupException: java.lang.IllegalStateException: No match found
        at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:125) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:112) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.cli.SettingCommand.execute(SettingCommand.java:54) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:122) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.cli.Command.main(Command.java:88) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:89) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:82) ~[elasticsearch-5.2.1.jar:5.2.1]
Caused by: java.lang.IllegalStateException: No match found
        at java.util.regex.Matcher.group(Matcher.java:536) ~[?:1.8.0_121]
        at org.elasticsearch.monitor.os.OsProbe.getControlGroups(OsProbe.java:216) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.monitor.os.OsProbe.getCgroup(OsProbe.java:414) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.monitor.os.OsProbe.osStats(OsProbe.java:466) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.monitor.os.OsService.<init>(OsService.java:45) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.monitor.MonitorService.<init>(MonitorService.java:45) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.node.Node.<init>(Node.java:345) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.node.Node.<init>(Node.java:232) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.bootstrap.Bootstrap$6.<init>(Bootstrap.java:241) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:241) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:333) ~[elasticsearch-5.2.1.jar:5.2.1]
        at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:121) ~[elasticsearch-5.2.1.jar:5.2.1]
        ... 6 more

参考 https://github.com/medcl/elasticsearch-rtf/issues/65 解决办法修改docker-compose.yaml watchad_elasticsearch: image: elasticsearch:5.3.0

Qianlitp commented 4 years ago

这个问题暂时没有出现,docker-compose.yaml只是一个建议的测试环境,目前ES支持5.X的所有版本,只要不是6.0及以上均可使用。