0
我試圖設置一個水槽劑源數據從系統日誌服務器。基本上,我在服務器(server1)上建立了一個系統日誌服務器來接收系統日誌事件,然後將所有消息轉發到安裝了flume代理的不同服務器(server2),最後所有數據都將匯聚到kafka集羣。源數據到水槽
水槽配置如下。
# For each one of the sources, the type is defined
agent.sources.syslogSrc.type = syslogudp
agent.sources.syslogSrc.port = 9090
agent.sources.syslogSrc.host = server2
# The channel can be defined as follows.
agent.sources.syslogSrc.channels = memoryChannel
# Each channel's type is defined.
agent.channels.memoryChannel.type = memory
# Other config values specific to each type of channel(sink or source)
# can be defined as well
# In this case, it specifies the capacity of the memory channel
agent.channels.memoryChannel.capacity = 100
# config for kafka sink
agent.sinks.kafkaSink.channel = memoryChannel
agent.sinks.kafkaSink.type = org.apache.flume.sink.kafka.KafkaSink
agent.sinks.kafkaSink.kafka.topic = flume
agent.sinks.kafkaSink.kafka.bootstrap.servers = <kafka.broker.list>:9092
agent.sinks.kafkaSink.kafka.flumeBatchSize = 20
agent.sinks.kafkaSink.kafka.producer.acks = 1
agent.sinks.kafkaSink.kafka.producer.linger.ms = 1
agent.sinks.kafkaSink.kafka.producer.compression.type = snappy
但是,莫名其妙地沒有注入flume agent。
appricate的建議。
喜@franklinsijo,我試圖改變服務器地址,並得到了以下異常。 org.jboss.netty.channel.ChannelException:無法綁定到:ldndsr000004895/10.75.24.139:9090 – Joey
是在主機'LISTEN'狀態的端口?你可以試試'netstat -napl | grep 9090'在server1上檢查端口的狀態? – franklinsijo
Rsyslog已經在'LISTEN'中 'tcp 0 0 0.0.0.0:9090 0.0.0.0:* LISTEN 37971/rsyslogd' @franklinsijo – Joey