How to properly configure Log4J 2?



I’m trying to configure Log4J2 in Java project after getting this message:

“No log4j2 configuration file found. Using default configuration: logging only errors to the console. Set system property 'log4j2.debug' to show Log4j2 internal initialization logging.”

As I understood, I should add to the classpath.

But, this file should also be located in Elastic’s config folder as mentioned here:

Should I manage this file in two location? One location is Elastic node and the second one in my Java project?

I think I’m missing something here, your help will be highly appreciated.


(David Pilato) #2

Are you using the TransportClient here?

May be read this:

(system) #3

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.