Flume错误:Sink hdfssink未连接到频道

时间:2017-10-17 15:25:39

标签: hadoop flume flume-ng

当我启动我的水槽代理时,我收到以下错误消息:

17/10/16 19:33:17 ERROR node.AbstractConfigurationProvider: Sink hdfssink has been removed due to an error during configuration
java.lang.IllegalStateException: Sink hdfssink is not connected to a channel
at org.apache.flume.node.AbstractConfigurationProvider.loadSinks(AbstractConfigurationProvider.java:419)
at org.apache.flume.node.AbstractConfigurationProvider.getConfiguration(AbstractConfigurationProvider.java:98)
at org.apache.flume.node.PollingPropertiesFileConfigurationProvider$FileWatcherRunnable.run(PollingPropertiesFileConfigurationProvider.java:140)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:304)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:178)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)
17/10/16 19:33:17 INFO node.AbstractConfigurationProvider: Channel loggerchannel connected to [logsource, loggersink]
17/10/16 19:33:17 INFO node.Application: Starting new configuration:{ sourceRunners:{logsource=EventDrivenSourceRunner: { source:org.apache.flume.source.ExecSource{name:logsource,state:IDLE} }} sinkRunners:{loggersink=SinkRunner: { policy:org.apache.flume.sink.DefaultSinkProcessor@5a311ade counterGroup:{ name:null counters:{} } }} channels:{loggerchannel=org.apache.flume.channel.MemoryChannel{name: loggerchannel}} }
 17/10/16 19:33:17 INFO node.Application: Starting Channel loggerchannel
17/10/16 19:33:17 INFO instrumentation.MonitoredCounterGroup: Monitored counter group for type: CHANNEL, name: loggerchannel: Successfully registered new MBean.
17/10/16 19:33:17 INFO instrumentation.MonitoredCounterGroup: Component type: CHANNEL, name: loggerchannel started
17/10/16 19:33:17 INFO node.Application: Starting Sink loggersink
17/10/16 19:33:17 INFO node.Application: Starting Source logsource
17/10/16 19:33:17 INFO source.ExecSource: Exec source starting with command:tail -F /opt/gen_logs/logs/access.log

它不会将任何文件写入hdfs接收器。我确实验证了每个&配置文件的每一行。下面是我的水槽配置文件:

fmp.sources = logsource
fmp.sinks = loggersink hdfssink
fmp.channels = loggerchannel hdfschannel

fmp.sources.logsource.type=exec
fmp.sources.logsource.command = tail -F /opt/gen_logs/logs/access.log

fmp.sinks.loggersink.type=logger
fmp.sinks.hdfssink.type=hdfs
fmp.sinks.hdfssink.hdfs.path=hdfs://quickstart.cloudera:8020/user/cloudera/flume

fmp.channels.loggerchannel.type=memory
fmp.channels.loggerchannel.capacity=1000
fmp.channels.loggerchannel.transactioncapacity=100

fmp.channels.hdfschannel.type=file
fmp.channels.hdfschannel.capacity=1000
fmp.channels.hdfschannel.transactioncapacity=100

fmp.sources.logsource.channels = hdfschannel loggerchannel
fmp.sinks.loggersink.channel = loggerchannel
fmp.sinks.hdfssink.channel = hdfschannel

0 个答案:

没有答案