Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Threaded View
MapReduce >> mail # user >> Re: Flume port issue


Copy link to this message
-
Re: Flume port issue
Lenin 
Thanks for your reply. 
Here is the 1st sample which works, i am not sure if you r referring to this:
-------------------------------
agent1.sources = netsource
agent1.sinks = logsink
agent1.channels = memorychannel

agent1.sources.netsource.type = netcat
agent1.sources.netsource.bind = localhost
agent1.sources.netsource.port = 3000

agent1.sinks.logsink.type = logger

agent1.channels.memorychannel.type = memory
agent1.channels.memorychannel.capacity = 1000
agent1.channels.memorychannel.transactionCapacity = 100

agent1.sources.netsource.channels = memorychannel
agent1.sinks.logsink.channel = memorychannel
-------------------------------

Please let me know if u have any suggestions.
Thanks
Sai
________________________________
 From: Lenin Raj <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Sent: Monday, 20 May 2013 5:54 PM
Subject: Re: Flume port issue
 
Sai, Are you able to run the netcat flume sample?
--
Lenin.
On May 20, 2013 5:40 PM, "Sai Sai" <[EMAIL PROTECTED]> wrote:

Not sure if this is the right group to ask questions about flume:
>
>
>I am getting an exception about unable to open a port in flume when trying to create a remote agent, more details below:
>---------------------------
>13/05/20 04:55:30 ERROR avro.AvroCLIClient: Unable to open connection to Flume. Exception follows.
>org.apache.flume.FlumeException: NettyAvroRpcClient { host: ubuntu, port: 41414 }: RPC connection error
>---------------------------
>
>
>
>Here r the steps i have followed:
>
>
>Step 1: Here is my agent3.conf created in the flume/conf dir:
>
>
>******
>agent3.sources = avrosource
>agent3.sinks = filesink
>agent3.channels = jdbcchannel
>
>
>agent3.sources.avrosource.type = avro
>agent3.sources.avrosource.bind = localhost
>agent3.sources.avrosource.port = 4000
>agent3.sources.avrosource.threads = 5
>
>
>agent3.sinks.filesink.type = FILE_ROLL
>agent3.sinks.filesink.sink.directory = /home/satish/work/apache-flume-1.3.1-bin/files
>agent3.sinks.filesink.sink.rollInterval = 0
>
>
>agent3.channels.jdbcchannel.type = jdbc
>
>
>agent3.sources.avrosource.channels = jdbcchannel
>agent3.sinks.filesink.channel = jdbcchannel
>
>
>******
>
>
>
>Step 2: Then i have saved it successfully and created a new test file like this:
>
>
>Step 3: echo "Hello World" > /home/satish/message3
>
>
>Step 4: Tried executing this command:
>
>
>./flume-ng avro-client -H localhost -p 4000 -F /home/satish/message3
>
>
>I get this exception below, please help:
>
>
>------------------------------
>
>
>Djava.library.path=:/home/satish/work/hadoop-1.0.4/libexec/../lib/native/Linux-i386-32 org.apache.flume.client.avro.AvroCLIClient -H ubuntu -p 41414 -F /usr/logs/log.10
>13/05/20 04:55:30 ERROR avro.AvroCLIClient: Unable to open connection to Flume. Exception follows.
>org.apache.flume.FlumeException: NettyAvroRpcClient { host: ubuntu, port: 41414 }: RPC connection error
>at org.apache.flume.api.NettyAvroRpcClient.connect(NettyAvroRpcClient.java:117)
>at org.apache.flume.api.NettyAvroRpcClient.connect(NettyAvroRpcClient.java:93)
>at org.apache.flume.api.NettyAvroRpcClient.configure(NettyAvroRpcClient.java:507)
>at org.apache.flume.api.RpcClientFactory.getDefaultInstance(RpcClientFactory.java:169)
>at org.apache.flume.client.avro.AvroCLIClient.run(AvroCLIClient.java:180)
>at org.apache.flume.client.avro.AvroCLIClient.main(AvroCLIClient.java:71)
>Caused by: java.io.IOException: Error connecting to ubuntu/127.0.0.1:41414
>at org.apache.avro.ipc.NettyTransceiver.getChannel(NettyTransceiver.java:261)
>at org.apache.avro.ipc.NettyTransceiver.<init>(NettyTransceiver.java:203)
>at org.apache.avro.ipc.NettyTransceiver.<init>(NettyTransceiver.java:152)
>at org.apache.flume.api.NettyAvroRpcClient.connect(NettyAvroRpcClient.java:106)
>... 5 more
>Caused by: java.net.ConnectException: Connection refused
>at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
>at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:592)
>at org.jboss.netty.channel.socket.nio.NioClientSocketPipelineSink$Boss.connect(NioClientSocketPipelineSink.java:396)