吹静静

欢迎QQ交流:592590682

报错背景

启动ES的时候报错。

报错现象

 

2020-09-03 12:13:46,131 main ERROR Unable to invoke factory method in class org.apache.logging.log4j.core.appender.RollingFileAppender for element RollingFile: java.lang.IllegalStateException: No factory method found for class org.apache.logging.log4j.core.appender.RollingFileAppender java.lang.IllegalStateException: No factory method found for class org.apache.logging.log4j.core.appender.RollingFileAppender
    at org.apache.logging.log4j.core.config.plugins.util.PluginBuilder.findFactoryMethod(PluginBuilder.java:235)
    at org.apache.logging.log4j.core.config.plugins.util.PluginBuilder.build(PluginBuilder.java:135)
    at org.apache.logging.log4j.core.config.AbstractConfiguration.createPluginObject(AbstractConfiguration.java:959)
    at org.apache.logging.log4j.core.config.AbstractConfiguration.createConfiguration(AbstractConfiguration.java:899)
    at org.apache.logging.log4j.core.config.AbstractConfiguration.createConfiguration(AbstractConfiguration.java:891)
    at org.apache.logging.log4j.core.config.AbstractConfiguration.doConfigure(AbstractConfiguration.java:514)
    at org.apache.logging.log4j.core.config.AbstractConfiguration.initialize(AbstractConfiguration.java:238)
    at org.apache.logging.log4j.core.config.AbstractConfiguration.start(AbstractConfiguration.java:250)
    at org.apache.logging.log4j.core.LoggerContext.setConfiguration(LoggerContext.java:547)
    at org.apache.logging.log4j.core.LoggerContext.start(LoggerContext.java:263)
    at org.elasticsearch.common.logging.LogConfigurator.configure(LogConfigurator.java:234)
    at org.elasticsearch.common.logging.LogConfigurator.configure(LogConfigurator.java:127)
    at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:310)
    at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:170)
    at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:161)
    at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:86)
    at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:125)
    at org.elasticsearch.cli.Command.main(Command.java:90)
    at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:126)
    at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:92)

报错原因

ES安装目录中出现文件的所属用户为root的情况,更改成普通用户即可。

报错解决

修改所属用户:

# chown es:es -R elasticsearch-7.6.1/

重启ES即可。

 

posted on 2020-09-03 12:22  吹静静  阅读(3974)  评论(0编辑  收藏  举报