-
Notifications
You must be signed in to change notification settings - Fork 16
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
Windows client should be configured with log rotation #165
Comments
I have a pull open here for the sensu-puppet project that fixes this via a xml template: sensu/sensu-puppet#621 Im using a limit of 10MB so that notepad doesnt hang when trying to open it, a total of 100MB should be sufficient for most places I would guess. Also TY I did not know this project existed :) |
It seems that the winsw log rotation is limited to the rotation of logs generated by winsw itself and not Sensu. We will be investigating adding log rotation to a future release. |
@amdprophet Im not sure thats true. Im using the following xml config:
My logs look like this: In side the logs it looks like this: Unless something is not being added in there (which is possible). I believe this is properly working. |
@dzeleski interesting - I wasn't using the logpath option but it seems like it is working. Have you had any issues with it removing the lock from the log files during rotation? |
@dzeleski I just noticed that your service definition doesn't include the |
Yes correct, apologies should have mentioned that. There may be a better way that you guys can handle it within the app itself but this is at least working for us currently. I have no idea if there are pros and cons and I assume either way there would be some testing that would need to validate it. |
Sensu 0.29.5 will include changes that add log rotation. Thanks for the input @dzeleski! |
Awesome! Ty. |
As described in sensu/sensu-puppet#618, the Windows client is not configured with log rotation by default. This can lead to large log files filling the disk, causing other failures as a result.
Looks like winsw has support for log rotation. Now that we have a sensu-client.xml that can start the service without additional configuration, I think we should probably configure log rotation by default as well.
The text was updated successfully, but these errors were encountered: