BTW, I corrected the miss matching port number. There is still nothing inside output.log file.
Anything else do I need to change in order to see the TcpInput goes into output.log file? Thanks, Emily On Thu, Jan 7, 2016 at 3:09 PM, Emily Gu <[email protected]> wrote: > Thanks David for all the help! I'll give it a try. > > Please bear with me as some parts I still not understand. > > 1. Why do I have to run two Heka instances where one for input and another > for output? > 2. Did you mean I need to specify different share_dirs in input and output > Toml configs? > 3. Do I need both TcpOutput and FileOutput in order for me to see messages > inside an output file? What if I didn't specify TcpOutput? > > Thanks, > Emily > > > > On Thu, Jan 7, 2016 at 2:59 PM, David Birdsong <[email protected]> > wrote: > >> 3242 != 3234 >> >> Also, make sure these are separate processes with fully configured and >> separate share_dirs. >> >> The same process will quickly spam itself into a tizzy very fast. >> >> >> On Thu, Jan 7, 2016 at 2:55 PM, Emily Gu <[email protected]> wrote: >> >>> Hi David, >>> >>> Thanks for your quick reply. My apology that I mixed questions together. >>> >>> Let's solve this TcpInput issue first. >>> >>> tcp_input.toml >>> ============ >>> >>> [tcp_in:3242] >>> >>> type = "TcpInput" >>> >>> splitter = "HekaFramingSplitter" >>> >>> decoder = "ProtobufDecoder" >>> >>> address = ":3242" >>> >>> >>> tcp_output.toml >>> >>> ============ >>> >>> >>> [tcp_out:3234] >>> >>> type = "TcpOutput" >>> >>> message_matcher = "TRUE" >>> >>> address = "127.0.0.1:3234" >>> >>> >>> [tcp_heka_output_log] >>> >>> type = "FileOutput" >>> >>> message_matcher = "TRUE" >>> >>> path = "/tmp/output.log" >>> >>> perm = "664" >>> >>> encoder = "tcp_heka_output_encoder" >>> >>> >>> [tcp_heka_output_encoder] >>> >>> type = "PayloadEncoder" >>> >>> append_newlines = false >>> >>> >>> I have the client program to send messages to "127.0.0.1:3234" and no >>> content in output.log generated. Am I doing anything wrong? >>> >>> >>> Thanks, >>> >>> Emily >>> >>> >>> >>> >>> >>> >>> On Thu, Jan 7, 2016 at 2:09 PM, David Birdsong <[email protected] >>> > wrote: >>> >>>> You will need to supply more of your toml since you've asked about >>>> TcpOutput but then follow up asking about TcpInput. >>>> >>>> Also, make sure you are not sending and receiving on the same heka >>>> instance. >>>> >>>> "that would be bad" >>>> >>>> On Thu, Jan 7, 2016 at 2:04 PM, Emily Gu <[email protected]> wrote: >>>> >>>>> Actually after I changed the port and ran TcpInput, I saw the >>>>> following in the console output: >>>>> >>>>> 2016/01/07 13:49:54 Input started: tcp_in:5656 >>>>> >>>>> 2016/01/07 13:56:53 Decoder 'tcp_in:5656-ProtobufDecoder-127.0.0.1': >>>>> stopped >>>>> >>>>> 2016/01/07 13:56:53 Decoder 'tcp_in:5656-ProtobufDecoder-127.0.0.1': >>>>> stopped >>>>> >>>>> 2016/01/07 14:00:16 Decoder 'tcp_in:5656-ProtobufDecoder-127.0.0.1': >>>>> stopped >>>>> >>>>> 2016/01/07 14:00:16 Decoder 'tcp_in:5656-ProtobufDecoder-127.0.0.1': >>>>> stopped >>>>> >>>>> Is the above alright? I'm programmally writing to TCP port 5656 and >>>>> would like to see the output in a file. >>>>> >>>>> Thanks, >>>>> >>>>> Emily >>>>> >>>>> >>>>> >>>>> >>>>> >>>>> On Thu, Jan 7, 2016 at 1:09 PM, Emily Gu <[email protected]> wrote: >>>>> >>>>>> Dear Heka, >>>>>> >>>>>> The example of TcpOutput plugin worked before. Now it stops working. >>>>>> The error I got is: >>>>>> >>>>>> 2016/01/07 13:04:25 Plugin 'tcp_out:9612' error: can't send record: >>>>>> can't connect: dial tcp 127.0.0.1:9612: getsockopt: connection >>>>>> refused >>>>>> >>>>>> >>>>>> The config I used is: >>>>>> >>>>>> [tcp_out:9612] >>>>>> >>>>>> type = "TcpOutput" >>>>>> >>>>>> message_matcher = "TRUE" >>>>>> >>>>>> address = "127.0.0.1:9612" >>>>>> >>>>>> >>>>>> Thanks for your timely help! >>>>>> >>>>>> Emily >>>>>> >>>>> >>>>> >>>>> _______________________________________________ >>>>> Heka mailing list >>>>> [email protected] >>>>> https://mail.mozilla.org/listinfo/heka >>>>> >>>>> >>>> >>> >> >
_______________________________________________ Heka mailing list [email protected] https://mail.mozilla.org/listinfo/heka

