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

"Library Log File" Grows With No Limit #80

Closed
eitansanvean opened this issue Apr 11, 2019 · 8 comments
Closed

"Library Log File" Grows With No Limit #80

eitansanvean opened this issue Apr 11, 2019 · 8 comments
Assignees
Labels
bug This issue is a bug.

Comments

@eitansanvean
Copy link

We're logging to CloudWatch in an application which sometimes runs without a network connection. This generates many errors and aws-logger-errors.txt can explode. These seems to be no way to control the size of this file.

We have a workaround which is to set LibraryLogFileName to null which stops all error logging.

@sattpat sattpat added the bug This issue is a bug. label Apr 12, 2019
@sattpat sattpat self-assigned this Apr 12, 2019
@sattpat
Copy link
Contributor

sattpat commented Apr 12, 2019

Hey, thanks for raising this issue. We certainly dont want to be logging every single issue. We would instead like to capture exceptions that are unique. Meaning that if you get exceptions as a result of network connection, we only log that once and we skip the repeats.
The other thing I wanted to raise here is that the logging library has a capacity and so if you are going offline, if the buffer has no additional capacity, the new logs would be lost. In the end the logs you will end up seeing on CW logs once you come online, will be the old logs. I am wondering if this is beneficial to you

@sattpat sattpat closed this as completed Apr 20, 2019
@sattpat
Copy link
Contributor

sattpat commented Apr 20, 2019

Closing this issue due to lack of activity. Feel free to reopen if additional follow up is needed

@LewisHamill
Copy link

We have just been in a position were the log file grew to over 20Gb in 4 days due to a permission related error with AWS it would seem. Still investigating the cause but this was a problem for us and I will now be disabling this log file seeing as there is no fix currently.

@kazim-Arshad
Copy link

Facing the same issue. Log file aws-logger-errors.txt size increases very rapidly to GBs when ever there is some connectivity issue to cloudwatch. A repetitive message gets logged to the file which increases file size.

@winzig
Copy link

winzig commented Aug 16, 2021

Just ran into the same issue today on an EC2 instance that recently had some new logging code enabled.

@winzig
Copy link

winzig commented Aug 16, 2021

@ashishdhingra Can this issue be re-opened/addressed?

@ashishdhingra
Copy link
Contributor

@winzig Looks like this issue was reported more than 2 years back and has a workaround available to disable logging by setting LibraryLogFileName to null. You may also control logging level by various configuration options when using specific logging library (NLog/Serilog/etc.). In case something else is required, since this issue is closed, request you to open a new issue (mentioning about this issue) along with the details in the issue/feature-request template.

@winzig
Copy link

winzig commented Aug 17, 2021

OK, well those things don't solve the problem. As sattpat mentioned in his initial reply, the real solution would be:

We certainly dont want to be logging every single issue. We would instead like to capture exceptions that are unique. Meaning that if you get exceptions as a result of network connection, we only log that once and we skip the repeats.

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

No branches or pull requests

6 participants