[英]Is it possible to increase Containerd log limit greater than 16K?
Our RKE2 environment uses Containerd as runtime.我们的 RKE2 环境使用 Containerd 作为运行时。 We have appllications that writes 50-60 KB lines to stdout and containerd is splitting this stdout logs to separated lines.我们有将 50-60 KB 行写入标准输出的应用程序,并且 containerd 正在将此标准输出日志拆分为单独的行。 Is it possible to increase character or size limit of log lines?是否可以增加日志行的字符或大小限制?
RKE2 version: 2.6.5 Kubernetes Version: v1.21.6+rke2r1 RKE2 版本:2.6.5 Kubernetes 版本:v1.21.6+rke2r1
I think there is no way to increase this log limit, but docker truncate the log when its size is bigger than 16KB without adding \n
, so if you use a tool to collect the log (ex: Fluented with concat plugin), you can re-aggregate these messages:我认为没有办法增加这个日志限制,但是 docker 在日志大小大于 16KB 时会截断日志而不添加\n
,所以如果您使用工具收集日志(例如:Fluented with concat plugin),您可以重新汇总这些消息:
<filter **>
@id filter_concat
@type concat
key log
use_first_timestamp true
multiline_end_regexp /\n$/
separator ""
</filter>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.