-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Closed
Labels
Description
Bug Report
Describe the bug
The fluent-bit collects the mycat log. When the log is too long, the fluentbit collects the log from the beginning again.
To Reproduce
- fluentbit conf
# ls
fluent-bit.conf parsers.conf
#
# cat fluent-bit.conf
[INPUT]
Name tail
tag mycat
path /var/log/mycat.log
Multiline On
Parser_Firstline mycat_error_log_parser_head
Parser_1 mycat_error_log_parser
Path_Key file
[SERVICE]
Flush 5
Daemon off
Log_Level debug
Parsers_File /fluent-bit/etc/parsers.conf
[FILTER]
Name record_modifier
Match *
Record hostname ${HOSTNAME}
Record AppName efk-mycat-test-ac234
Record ConfigType Fluentbit
Record CreatedBy orain.com
Record DBType mysql
Record ProxyType mycat
Record Type Proxy
[OUTPUT]
Name es
Match *
Include_Tag_Key True
Host elasticsearch-logging.kube-system.svc
Port 9200
Logstash_Format True
Time_Key time
Type proxy
#
#
# cat parsers.conf
[PARSER]
Name mycat_error_log_parser_head
Format regex
Regex ^(?<time>\d{4}-\d{1,2}-\d{1,2}(\S)+\W(\S)+)(\s+)(?<logType>\S+)(\s+)(?<no>\S+)(\s+)(?<content>(.|\n)*)
Time_Offset +0800
Time_Format %Y-%m-%d %H:%M:%S.%L
Time_Keep Off
[PARSER]
Name mycat_error_log_parser
Format regex
Regex .*
- The log of fluentbit
[2018/09/03 11:38:49] [debug] [task] destroy task=0x7f6f6f064000 (task_id=0)
[2018/09/03 11:38:49] [debug] [dyntag tail.0] 0x7f6f6f140440 destroy (tag=mycat)
[2018/09/03 11:39:44] [debug] [in_tail] append new file: /var/log/mycat.log
[2018/09/03 11:39:44] [debug] [in_tail] add to scan queue /var/log/mycat.log, offset=0
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 353
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 775
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 1204
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 1602
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 1919
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 2427
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 4065
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 4380
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 4692
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 5010
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 5322
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 5645
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 5967
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 6300
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 6627
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 6941
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 7276
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 7610
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 7945
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 8256
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 8645
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 9048
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 9726
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 10090
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 10429
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 10768
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 11103
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 11418
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 11807
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 12260
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 12713
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 13166
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 13619
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 14072
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 14525
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 14978
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 15431
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 15884
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 16337
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 16790
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 17243
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 17643
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 18043
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 18443
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 18843
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 19243
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 19643
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 20043
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 20443
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 20843
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 21243
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 21643
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 22144
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 22645
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 23012
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 23667
[2018/09/03 11:39:44] [debug] [input tail.0] [mem buf] size = 24321
[2018/09/03 11:39:44] [debug] [in_tail] file=/var/log/mycat.log read=32767 lines=59
[2018/09/03 11:39:44] [debug] [in_tail] file=/var/log/mycat.log read=14321 lines=0
[2018/09/03 11:39:44] [error] [in_tail] file=/var/log/mycat.log requires a larger buffer size, lines are too long. Skipping file.
[2018/09/03 11:39:49] [debug] [task->buffer] worker_id=0
[2018/09/03 11:39:49] [debug] [task] created task=0x7f6f6f064000 id=0 OK
[2018/09/03 11:39:49] [debug] [out_es] HTTP Status=200
[2018/09/03 11:39:49] [debug] [out_es Elasticsearch response
{"took":58,"errors":false,"items":[{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdg-XYKMlFHdwBd7QA","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdg-XYKMlFHdwBd7QB","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdg-XYKMlFHdwBd7QC","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdg-XYKMlFHdwBd7QD","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdg-XYKMlFHdwBd7QE","_version":1,"result":"created","_shards":{"tot
[2018/09/03 11:39:49] [debug] [task] destroy task=0x7f6f6f064000 (task_id=0)
[2018/09/03 11:39:49] [debug] [dyntag tail.0] 0x7f6f6f140440 destroy (tag=mycat)
[2018/09/03 11:40:43] [debug] [in_tail] append new file: /var/log/mycat.log
[2018/09/03 11:40:43] [debug] [in_tail] add to scan queue /var/log/mycat.log, offset=0
[2018/09/03 11:40:43] [debug] [input tail.0] [mem buf] size = 353
[2018/09/03 11:40:43] [debug] [input tail.0] [mem buf] size = 775
[2018/09/03 11:40:43] [debug] [input tail.0] [mem buf] size = 1204
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 1602
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 1919
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 2427
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 4065
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 4380
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 4692
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 5010
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 5322
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 5645
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 5967
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 6300
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 6627
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 6941
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 7276
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 7610
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 7945
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 8256
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 8645
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 9048
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 9726
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 10090
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 10429
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 10768
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 11103
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 11418
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 11807
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 12260
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 12713
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 13166
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 13619
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 14072
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 14525
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 14978
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 15431
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 15884
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 16337
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 16790
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 17243
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 17643
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 18043
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 18443
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 18843
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 19243
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 19643
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 20043
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 20443
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 20843
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 21243
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 21643
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 22144
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 22645
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 23012
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 23667
[2018/09/03 11:40:44] [debug] [input tail.0] [mem buf] size = 24321
[2018/09/03 11:40:44] [debug] [in_tail] file=/var/log/mycat.log read=32767 lines=59
[2018/09/03 11:40:44] [debug] [in_tail] file=/var/log/mycat.log read=14321 lines=0
[2018/09/03 11:40:44] [error] [in_tail] file=/var/log/mycat.log requires a larger buffer size, lines are too long. Skipping file.
[2018/09/03 11:40:49] [debug] [task->buffer] worker_id=0
[2018/09/03 11:40:49] [debug] [task] created task=0x7f6f6f064000 id=0 OK
[2018/09/03 11:40:49] [debug] [out_es] HTTP Status=200
[2018/09/03 11:40:49] [debug] [out_es Elasticsearch response
{"took":44,"errors":false,"items":[{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdhNA4KMlFHdwBd7Q6","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdhNA4KMlFHdwBd7Q7","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdhNA4KMlFHdwBd7Q8","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdhNA4KMlFHdwBd7Q9","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdhNA4KMlFHdwBd7Q-","_version":1,"result":"created","_shards":{"tot
[2018/09/03 11:40:49] [debug] [task] destroy task=0x7f6f6f064000 (task_id=0)
[2018/09/03 11:40:49] [debug] [dyntag tail.0] 0x7f6f6f140440 destroy (tag=mycat)
[2018/09/03 11:41:44] [debug] [in_tail] append new file: /var/log/mycat.log
[2018/09/03 11:41:44] [debug] [in_tail] add to scan queue /var/log/mycat.log, offset=0
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 353
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 775
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 1204
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 1602
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 1919
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 2427
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 4065
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 4380
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 4692
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 5010
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 5322
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 5645
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 5967
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 6300
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 6627
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 6941
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 7276
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 7610
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 7945
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 8256
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 8645
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 9048
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 9726
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 10090
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 10429
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 10768
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 11103
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 11418
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 11807
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 12260
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 12713
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 13166
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 13619
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 14072
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 14525
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 14978
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 15431
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 15884
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 16337
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 16790
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 17243
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 17643
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 18043
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 18443
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 18843
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 19243
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 19643
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 20043
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 20443
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 20843
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 21243
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 21643
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 22144
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 22645
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 23012
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 23667
[2018/09/03 11:41:44] [debug] [input tail.0] [mem buf] size = 24321
[2018/09/03 11:41:44] [debug] [in_tail] file=/var/log/mycat.log read=32767 lines=59
[2018/09/03 11:41:44] [debug] [in_tail] file=/var/log/mycat.log read=14321 lines=0
[2018/09/03 11:41:44] [error] [in_tail] file=/var/log/mycat.log requires a larger buffer size, lines are too long. Skipping file.
[2018/09/03 11:41:49] [debug] [task->buffer] worker_id=0
[2018/09/03 11:41:49] [debug] [task] created task=0x7f6f6f064000 id=0 OK
[2018/09/03 11:41:49] [debug] [out_es] HTTP Status=200
[2018/09/03 11:41:49] [debug] [out_es Elasticsearch response
{"took":69,"errors":false,"items":[{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdhbqaKMlFHdwBd7R0","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdhbqaKMlFHdwBd7R1","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdhbqaKMlFHdwBd7R2","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdhbqaKMlFHdwBd7R3","_version":1,"result":"created","_shards":{"total":2,"successful":1,"failed":0},"created":true,"status":201}},{"index":{"_index":"logstash-2018.09.03","_type":"proxy","_id":"AWWdhbqaKMlFHdwBd7R4","_version":1,"result":"created","_shards":{"tot
...
-
The log of mycat
mycat.log
Your Environment
- Version used: Fluent Bit v0.12.9
- Environment name and version (e.g. Kubernetes? What version?): Kubernetes 1.10.5
- Operating System and version: Linux efk-mycat-test-ac234-proxy-0 3.10.0-693.el7.x86_64 Fix include paths #1 SMP Thu Jul 6 19:56:57 EDT 2017 x86_64 GNU/Linux
Any help would be appreciated.
Reactions are currently unavailable
