-
What is a problem?I've been trying to diagnose high error rates with system log collection on my network. I can't seem to identify a configuration that results in proper receipt of logs from the OpenBSD built-in syslogd without seeing TimeParseError from Fluentd. Looking at the error, I can't see why it occurs, as the timestamps appear to be correct. Sample error and received log line detail: 2024-04-14 01:40:23 -0700 [error]: #0 invalid input data="<30>Apr 14 01:40:23 unbound: [91920:0] info: 10.0.x.xx xxxxxxxx.xxx.xxxxxx.net. A IN" error_class=Fluent::TimeParser::TimeParseError error="invalid time format: value = Apr 14 01:40:23, error_class = ArgumentError, error = string doesn't match"
2024-04-14 01:40:23 -0700 [error]: #0 /usr/local/lib/ruby/gems/3.2/gems/fluentd-1.16.5/lib/fluent/time.rb:280:in `rescue in parse'
2024-04-14 01:40:23 -0700 [error]: #0 /usr/local/lib/ruby/gems/3.2/gems/fluentd-1.16.5/lib/fluent/time.rb:277:in `parse'
2024-04-14 01:40:23 -0700 [error]: #0 /usr/local/lib/ruby/gems/3.2/gems/fluentd-1.16.5/lib/fluent/plugin/parser_syslog.rb:193:in `block in parse_rfc3164_regex'
2024-04-14 01:40:23 -0700 [error]: #0 /usr/local/lib/ruby/gems/3.2/gems/fluentd-1.16.5/lib/fluent/plugin/parser_syslog.rb:193:in `synchronize'
2024-04-14 01:40:23 -0700 [error]: #0 /usr/local/lib/ruby/gems/3.2/gems/fluentd-1.16.5/lib/fluent/plugin/parser_syslog.rb:193:in `parse_rfc3164_regex'
2024-04-14 01:40:23 -0700 [error]: #0 /usr/local/lib/ruby/gems/3.2/gems/fluentd-1.16.5/lib/fluent/plugin/in_syslog.rb:241:in `message_handler'
2024-04-14 01:40:23 -0700 [error]: #0 /usr/local/lib/ruby/gems/3.2/gems/fluentd-1.16.5/lib/fluent/plugin/in_syslog.rb:174:in `block in start_udp_server'
2024-04-14 01:40:23 -0700 [error]: #0 /usr/local/lib/ruby/gems/3.2/gems/fluentd-1.16.5/lib/fluent/plugin_helper/server.rb:570:in `on_readable_with_sock'
2024-04-14 01:40:23 -0700 [error]: #0 /usr/local/lib/ruby/gems/3.2/gems/cool.io-1.7.1/lib/cool.io/io.rb:186:in `on_readable'
2024-04-14 01:40:23 -0700 [error]: #0 /usr/local/lib/ruby/gems/3.2/gems/cool.io-1.7.1/lib/cool.io/loop.rb:88:in `run_once'
2024-04-14 01:40:23 -0700 [error]: #0 /usr/local/lib/ruby/gems/3.2/gems/cool.io-1.7.1/lib/cool.io/loop.rb:88:in `run'
2024-04-14 01:40:23 -0700 [error]: #0 /usr/local/lib/ruby/gems/3.2/gems/fluentd-1.16.5/lib/fluent/plugin_helper/event_loop.rb:93:in `block in start'
2024-04-14 01:40:23 -0700 [error]: #0 /usr/local/lib/ruby/gems/3.2/gems/fluentd-1.16.5/lib/fluent/plugin_helper/thread.rb:78:in `block in thread_create' Apr 14 01:40:23 appears to be the valid format for RFC 3164 format timestamps. What else I've tried
Error; seems like framing changed with change to TCP:
From this I've then set
Same when reverting to traditional timestamp format with TCP:
Describe the configuration of FluentdFluentd test configuration:
OpenBSD syslogd(8) test configuration:
syslogd is executed with a default configuration (no modified flags, so it emits standard RFC 3164 events and traditional timestamps. Describe the logs of FluentdFluentd startup:
Environment- Fluentd version: fluentd32 1.16.5
- Ruby version: ruby 3.2.3 (2024-01-18 revision 52bb2ac0a6) [x86_64-openbsd]
- Operating system: OpenBSD 7.4 amd64 |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Thanks for the detailed report. I can't reproduce it. Config: <source>
@type syslog
tag test
</source>
<match test.**>
@type stdout
</match> Command to send syslog: echo "<30>Apr 14 01:40:23 unbound: [91920:0] info: 10.0.x.xx xxxxxxxx.xxx.xxxxxx.net. A IN" | nc -u 0.0.0.0 5140 Standard output of Fluentd:
|
Beta Was this translation helpful? Give feedback.
-
I found at least one configuration that works without resulting in an error: syslogd(8) flags:
syslogd.conf(5) forwarding entry:
fluentd in_udp source:
|
Beta Was this translation helpful? Give feedback.
I found at least one configuration that works without resulting in an error:
syslogd(8) flags:
syslogd_flags=-h -Z -u
syslogd.conf(5) forwarding entry:
*.*;mail.info @127.0.0.1:5140
fluentd in_udp source: