Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider current log file size for rotating #6845

Closed
gerasym opened this issue Jan 2, 2020 · 1 comment
Closed

Consider current log file size for rotating #6845

gerasym opened this issue Jan 2, 2020 · 1 comment

Comments

@gerasym
Copy link

gerasym commented Jan 2, 2020

Feature Request

Consider current log file size for rotating

Proposal:

It would be better to set https://github.com/influxdata/telegraf/blob/master/internal/rotate/file_writer.go#L109 to current file size

Current behavior:

Logfile is rotated only when bytesWritten reaches logfile_rotation_max_size, which means if telegraf was restarted/crashed logfile will not be rotated.

Desired behavior:

Rotate logfile when it's size exceeds logfile_rotation_max_size

Use case: This is just more reliable

@danielnelson
Copy link
Contributor

This is a duplicate of #6776.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants