如何禁用filebeat的close_inactive设置? [英] How do I disable filebeat's close_inactive setting?

查看:1477
本文介绍了如何禁用filebeat的close_inactive设置?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的文件拍(来自docker.elastic.co/beats/filebeat:6.1.2的容器)收割机被close_inactive关闭,我不希望它们关闭.来自close_inactive中的文档>这里声明

My filebeat (container from docker.elastic.co/beats/filebeat:6.1.2) harvesters are being closed by the close_inactive and I don't want them to be. The documentation from close_inactive from here states

启用此选项后,如果在指定时间内未收获文件,Filebeat将关闭文件句柄.

When this option is enabled, Filebeat closes the file handle if a file has not been harvested for the specified duration.

...

您可以使用2h(2小时)和5m(5分钟)之类的时间字符串.默认值为5m.

You can use time strings like 2h (2 hours) and 5m (5 minutes). The default is 5m.

5分钟后,我的文件句柄被关闭.我知道我可以增加close_inactive时间,但是第一句话表明可以完全禁用该选项.

My file handles are being closed after 5 minutes. I know I can increase the close_inactive time, but the first sentence indicates that the option can be disabled altogether.

我尝试过类似close_inactive: false的方法,但是没有运气.如何禁用close_inactive设置?

I've tried things like close_inactive: false but no luck. How do I disable the close_inactive setting?

推荐答案

如果在filebeat.yml中添加选项close_inactive: -1,Filebeat将永远不会关闭文件.

If you add the option close_inactive: -1 in your filebeat.yml, Filebeat will never close the file.

这篇关于如何禁用filebeat的close_inactive设置?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆