Badb0y
(Bad)
October 1, 2018, 6:13am
1
Hi,
We have this configuration:
filebeat.prospectors:
- type: log
enabled: true
exclude_lines: ['^#']
paths:
- D:\dir\logfiles\zip_archive\www.dir.com\*\u*.log
- D:\dir\logfiles\zip_archive\www81.dir.com\*\u*.log
fields_under_root: true
fields:
type: webreturn
- type: log
enabled: true
exclude_lines: ['^#']
paths:
- D:\dir\logfiles\zip_archive\http_sys_logs\HTTPERR\h*.log
fields_under_root: true
fields:
type: httperr
filebeat.config.modules:
path: ${path.config}/modules.d/*.yml
reload.enabled: false
output.logstash:
hosts: ["hostslist"]
This is running on windows and we have a file deletion in this folder, so all files that is older than 2 days got deleted.
However filebeat is still reading the file and it prevents to delete it.
How can I set it to let the task scheduler delete it?
I'm using 6.2.4 version.
Badb0y
(Bad)
October 1, 2018, 6:24am
3
Yes, but don't know which and how to implement? The close_inactive? Or ?
Badb0y
(Bad)
October 1, 2018, 6:24am
4
Yes, but don't know which and how to implement? The close_inactive? Or ?
I do not know the lifecycle of your files or how long they are written to, but close_inactive
might certainly be an option.
What does your config look like now? What exactly does not work?
Badb0y
(Bad)
October 8, 2018, 9:13am
8
filebeat.prospectors:
- type: log
close_inactive: 60m
enabled: true
exclude_lines: ['^#']
paths:
- D:\a\logfiles\zip_archive\www.aa.com\*\u*.log
- D:\a\logfiles\zip_archive\www81.aa.com\*\u*.log
fields_under_root: true
fields:
type: webreturn
ignore_older: 24h
- type: log
close_inactive: 60m
enabled: true
exclude_lines: ['^#']
paths:
- D:\a\logfiles\zip_archive\http_sys_logs\HTTPERR\h*.log
fields_under_root: true
fields:
type: httperr
filebeat.config.modules:
path: ${path.config}/modules.d/*.yml
reload.enabled: false
output.logstash:
hosts: ["hosts"]
system
(system)
Closed
November 5, 2018, 9:13am
9
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.