Query regarding redirecting fluentd's own logs to a file and then using stdout in match directive #4032
pratikshavyas
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
I have a use case to redirect fluentd's own logs to a file which is done by the below option:
fluentd -o /path/to/log_file
I have another requirement where I need to read logs from a different file and send it to stdout. I have used below config to achieve this by having a source section to read from the file and then a match section with stdout type.
\<source\> @type tail path /tmp/*.log pos_file /tmp/td-agent.pos read_from_head true tag test \<parse\> @type json \</parse\> \</source\> \<match test\> @type stdout \<format\> @type json \</format\> \</match\>
However, I observe that even logs from this file path is also going to the redirected log file only and not coming to stdout.
Is this expected behaviour and please suggest some way to achieve the above explained use case.
Thanks in advance.
Beta Was this translation helpful? Give feedback.
All reactions