Sorry, yes I was going to mention that I added this support as noted by Sean. However, it only works when the configuration in in properties format. Flume is currently packaged with an XML configuration, probably because I hate the properties format. But as Sean notes, this could be resolved by converting log4j2.xml to log4j2.properties and making sure to include the system property reference.
Ralph > On Jun 14, 2022, at 9:59 AM, Sean Busbey <sbus...@apple.com.INVALID> wrote: > > Log4j 2.17.2 added the needed building blocks via LOG4J2-3341 at the request > of the Hadoop and HBase projects. > > For example, the out of the box HBase log4j2.properties file includes several > references to system properties, including this for the root logger: > > ``` > rootLogger = ${sys:hbase.root.logger:-INFO,console} > ``` > > And then our out of the box bootstrapping scripts include setting the > parameter based on an environment variable: > > ``` > HBASE_OPTS="$HBASE_OPTS > -Dhbase.root.logger=${HBASE_ROOT_LOGGER:-INFO,console}" > ``` > > We could implement something similar to allow setting a system property to > change the root logger. > >> On Jun 13, 2022, at 4:33 PM, Tristan Stevens <tris...@apache.org> wrote: >> >> Hi Ralph, >> That's the one that I had trouble with. Is there an equivalent system >> parameter that you can set to get the same behaviour with log4j2? >> >> Tristan >> >> Get Outlook for Android<https://aka.ms/AAb9ysg> >> >> ________________________________ >> From: Ralph Goers <ralph.go...@dslextreme.com> >> Sent: Monday, 13 June 2022, 22:04 >> To: dev@flume.apache.org <dev@flume.apache.org> >> Subject: Log4j & user doc >> >> Tristan, >> >> Although I see references to -Dflume.root.logger I see no place that >> actually implements support for it. So I removed those from the >> documentation. >> >> There are still references to Log4j 1 but those are all for Flumeās Log4j >> Appender, which still targets Log4j 1. >> >> Please review the Flume web site for any other issues there. >> >> Ralph >> > >