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

Set sane defaults for logging and rotation. #13

Open
bflanagin opened this issue Jul 23, 2021 · 1 comment
Open

Set sane defaults for logging and rotation. #13

bflanagin opened this issue Jul 23, 2021 · 1 comment

Comments

@bflanagin
Copy link

Is your feature request related to a problem? Please describe.
Currently journald has no set limit on how much storage space can be used, or should be kept free causing boot issues and other unwanted conditions.

Describe the solution you'd like
/etc/systemd/journald.conf has an option that can be set to limit the amount of space the logs can take up on the system (SystemMaxUse) as well as an option to ensure that a certain amount of space is left on the drive (SystemKeepFree). I believe both of these need to be set to mitigate the issues users are facing.

For an example I've set the two options locally as follows:
SystemMaxUse=1GB
SystemKeepFree=10GB.

Describe alternatives you've considered

There are a few other options that could be set if we are concerned with missing important information when setting the log size too low. Along with the above options there are rotation options that can be set which are labeled "MaxFileSec" and "MaxRetentionSec".

Notes:
I'm currently testing this solution to make sure it works as expected. Will verify and update ticket.

@bflanagin
Copy link
Author

After talking with support, it may be better to use MaxFileSec to ensure that enough information is stored for debugging purposes. They suggest 1month is enough (which seems to be default)

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

1 participant