Flume - flume.root.logger = DEBUG, only the console logs INFO level log messages

I installed Flume 1.4.0-cdh4.7.0 on CentOS (cloudera VM)

I ran the following command to run flum

flume-ng agent -n agent-name -c conf -f conf / flume.conf -Dflume.root.looger = DEBUG, console

but it only writes the default level (INFO) to the console. I can not understand why?

+5
source share
4 answers

There is a typo on the command line:

flume-ng agent -n agent-name -c conf -f conf/flume.conf -Dflume.root.looger=DEBUG,console 

It says root.looger instead of root.logger , so the command line parameter is overridden by something in the log4j.propeties file

+4
source

The -Dflume.root.logger property overrides the root log in conf / log4j.properties to use the console application. If you did not redefine the root log, everything will still work, but the output will work with the log / flume.log file . Of course, you can also just edit the conf / log4j.properties file and change the flume.root.logger property (or anything else you like).

+3
source

This will not work if the tray directory (which contains the flume-ng shell) is placed on the PATH. You must run it from the root of the root directory and place the desired logging level inside conf / log4j.properties , in this case DEBUG. Then and only then it will enter the file or console at the desired level.

+1
source

You should use this to get debug level information in the console.

bin / flume-ng agent --conf./conf/-f conf / flume.conf -Dflume.root.logger = DEBUG, console -n agent

0
source

Source: https://habr.com/ru/post/1207963/


All Articles