current position:Home>Start the flume script and report an error in the generated log file: agent configuration for 'A1' has no configfilters

Start the flume script and report an error in the generated log file: agent configuration for 'A1' has no configfilters

2022-02-02 23:41:23 CSDN Q & A

In the process of graduation design , In Datong kafka-flume-hdfs Channel time ,hdfs Can't receive flume Collected data , see flume Error found in startup log file :

No configuration directory set! Use --conf <dir> to override.2021-12-17 13:49:27,952 WARN conf.FlumeConfiguration: Agent configuration for 'a1' has no configfilters.

This is my flume Profile contents

##  Components a1.sources=r1a1.channels=c1a1.sinks=k1## source1a1.sources.r1.type=org.apache.flume.source.kafka.KafkaSourcea1.sources.r1.batchSize=5000a1.sources.r1.batchDurationMillis=2000a1.sources.r1.kafka.bootstrap.servers=hadoop102:9092,hadoop103:9092,hadoop104:9092a1.sources.r1.kafka.topics=topic_log##  Time stamp interceptor # a1.sources.r1.interceptors=i1# a1.sources.r1.interceptors.i1.type=cn.fzy.flume.interceptor.TimeStampInterceptor$Builder## channel1a1.channels.c1.type=filea1.channels.c1.checkpointDir=/opt/module/flume/checkpoint/behavior1a1.channels.c1.dataDirs=/opt/module/flume/data/behavior1/## sink1a1.sinks.k1.type=hdfsa1.sinks.k1.hdfs.path=/origin_data/gmall/log/topic_log/%Y-%m-%da1.sinks.k1.hdfs.filePrefix=log-a1.sinks.k1.hdfs.round = false##  Control the generated small files a1.sinks.k1.hdfs.rollInterval = 10a1.sinks.k1.hdfs.rollSize = 134217728a1.sinks.k1.hdfs.rollCount = 0##  The control output file is a native file .a1.sinks.k1.hdfs.fileType = CompressedStreama1.sinks.k1.hdfs.codeC = lzop##  assemble a1.sources.r1.channels = c1a1.sinks.k1.channel= c1

This is my command statement

nohup /opt/module/flume/bin/flume-ng agent \--conf-file /opt/module/flume/conf/kafka-flume-hdfs.conf \--name a1 -Dflume.root.logE >/opt/module/flume/log2.txt   2>&1 &

Programming for Baidu , If you have a problem, go to Baidu directly , Many share that the name of the configuration is a1 In the command statement, it's like a1, But the name in my command statement is the same as the component name in the configuration file , I don't know why , Please take a look , Thank you for the




Refer to the answer 1:

The problem of starting the command , Try this. :
nohup /opt/module/flume/bin/flume-ng agent --conf /opt/module/flume/conf -f /opt/module/flume/conf/kafka-flume-hdfs.conf -Dflume.root.logger=INFO,console -n a1 >/opt/module/flume/log2.txt 2>&1




Refer to the answer 2:

copyright notice
author[CSDN Q & A],Please bring the original link to reprint, thank you.
https://en.primo.wiki/2022/02/202202022341204499.html

Random recommended