-
Notifications
You must be signed in to change notification settings - Fork 239
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
Add logfile rotation, and delete log files when running crc delete --clear-cache
#3720
Conversation
You mean this happens continuously ? |
yes, this keeps on happening making new backup files and new log files |
I even question the |
crc delete --clear-cache
crc delete --clear-cache
yeah, its not very intuitive, but since we always had a but deleting the log files also with the with the log file rotation added and the number of backups also configurable (set to 10 backups in this PR) the deleting of log files might not be needed at all. |
i doubt many users inow about this. i see many users with gigs stored in their cache. what does telemetry show? I'd rather go for the more intuitive option |
you mean, not remove the log files with any command and do it automatically, i.e drop this commit b1b06ac from the PR ? @gbraad or should we remove the need to supply |
why we need 10 backups? shouldn't we just OK with 2 or even single one, as a user I check those logs file only when I hit an error to understand what I have as part of debug and share it during issue creation apart from that I might not care about this log file or is there any other use case of these backups? |
i added 10 backups, thinking 5mb limit will be reached soon because of all the status calls to the daemon and we might lose logs, but only 2 should be sufficient and we can always change this if we discover we're losing some logs, update the PR! |
@anjannath looks like during the update you added the other commits also? |
the `crc delete --clear-cache` command will now also remove the crc.log and crcd.log files
both the crc.log and crcd.log files will be rotated (backed up by renaming and creating a new log file) after they grow to 5 MBs in size
@praveenkumar yeah, i rebased on the other PR branch it seems, was supposed to rebase on main, updated again, thanks! |
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: praveenkumar The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/retest |
/test e2e-crc |
@anjannath: The following test failed, say
Full PR test history. Your PR dashboard. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here. |
unrelated to the PR, but from another PR https://prow.ci.openshift.org/view/gs/origin-ci-test/pr-logs/pull/crc-org_crc/3748/pull-ci-crc-org-crc-main-e2e-crc/1676523231856562176 |
This is a known issue already reported on the community operators project redhat-openshift-ecosystem/community-operators-prod#2865 |
currently after crc-org#3720 was merged it is only deleting the 'crc.log' and 'crcd.log' files and not deleting the backups
currently after crc-org#3720 was merged it is deleting the 'crc.log' and 'crcd.log' files and not deleting the backups this adds deletion of the backed up log files named crc-*.log and removes deletion of the crc.log file which is handled by 'crc cleanup' it removes the deletion of crcd.log file as when delete is performed the daemon still keeps running in the background
currently after crc-org#3720 was merged it is deleting the 'crc.log' and 'crcd.log' files and not deleting the backups this adds deletion of the backed up log files named crc-*.log and removes deletion of the crc.log file which is handled by 'crc cleanup' it removes the deletion of crcd.log file as when delete is performed the daemon still keeps running in the background
currently after crc-org#3720 was merged it is deleting the 'crc.log' and 'crcd.log' files and not deleting the backups this adds deletion of the backed up log files named crc-*.log and removes deletion of the crc.log file which is handled by 'crc cleanup' it removes the deletion of crcd.log file as when delete is performed the daemon still keeps running in the background
currently after crc-org#3720 was merged it is deleting the 'crc.log' and 'crcd.log' files and not deleting the backups this adds deletion of the backed up log files named crc-*.log and removes deletion of the crc.log file which is handled by 'crc cleanup' it removes the deletion of crcd.log file as when delete is performed the daemon still keeps running in the background
currently after #3720 was merged it is deleting the 'crc.log' and 'crcd.log' files and not deleting the backups this adds deletion of the backed up log files named crc-*.log and removes deletion of the crc.log file which is handled by 'crc cleanup' it removes the deletion of crcd.log file as when delete is performed the daemon still keeps running in the background
both the crc.log and crcd.log files will be rotated (backed up by
renaming and creating a new log file) after they grow to 5 MBs in
size