Created
July 21, 2016 05:32
-
-
Save M2shad0w/e305262198768d2a9313be6a0ed96db0 to your computer and use it in GitHub Desktop.
flume数据传输到Avro sink
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Define source, channel, sink | |
agent1.sources = r1 | |
agent1.channels = ch2 | |
agent1.sinks = avro-sink1 | |
# Configure channel | |
agent1.channels.ch2.type = file | |
agent1.channels.ch2.capacity = 1000000 | |
agent1.channels.ch2.transactionCapacity = 500000 | |
agent1.sinks.avro-sink1.type = avro | |
agent1.sinks.avro-sink1.channel = ch2 | |
agent1.sinks.avro-sink1.hostname = x.x.x.x | |
agent1.sinks.avro-sink1.port = 5641 | |
# Define and configure an Spool directory source | |
agent1.sources.r1.channels = ch2 | |
agent1.sources.r1.type = exec | |
agent1.sources.r1.command = tail -F /alidata/log/nginx/access.log | |
agent1.sources.r1.interceptors = i1 | |
agent1.sources.r1.interceptors.i1.type = host | |
agent1.sources.r1.interceptors.i1.hostHeader = hostname |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment