-
-
Notifications
You must be signed in to change notification settings - Fork 236
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
After using ansible redis
roles, pmproxy.log filled our log volume
#1536
Comments
Why are PCP processes logging to disk in separate files? Why isn't it using syslog logging to land in journald? |
We've an open ticket for that: #1040 but it didn't get much traction so far.
Did Redis run out of disk space while snapshotting, could you check the Redis logs? |
We used the The errors in the redis logs say:
But the only thing using substantial disk space is the After expanding the volume, the redis service is back to normal. |
Redis by default is snapshotting its entire database periodically on disk. When you restart Redis, it will load the contents of
Looks like Redis stops all write requests if it can't snapshot the database to the disk successfully. Makes sense from a durability point of view, otherwise you'll loose data when Redis gets restarted. In PCP we log all errors coming from Redis. Not sure what's the best solution in this case - keep track of logged errors and only log each Redis error type once? We have this implemented for Redis reconnect (to not flood the pmproxy log with "trying to connect to redis..." messages), but I'm not 100% convinced that it makes sense to apply this for every single error type. What do you think @natoscott? |
This is why I asked about PCP logging to files. If it logged to journald either vis syslog or stdout/stderr from systemd process creation, then the disk would not have filled up. |
Ah, because journald automatically manages log rotation. Yep, I'm also very much in favor of supporting journald. afaics we have the following options I think option a) is the cleanest but the most effort, alternatively option b) is also fine imho. |
@andreasgerstmayr I believe this is one of the areas @goodwinos is planning on tackling for PCP v6. Another option (e.g. non-systemd and/or pre v6) would be to install logrotate(8) files. I don't think we can reliably attempt to throttle logging of all possible Redis issues in pmproxy, and logrotate is a generic solution we could apply to other PCP daemon logs as well. |
See this P99 talk on the problem with logging. Until we properly solved that, for system administrators, |
Just to be sure, here is a series of
|
It's not a bad idea IMO. I can see no gain from continually re-logging the same error repeatedly for continually failing operations - culling or rate limiting to perhaps once per day makes more sense to me. |
To summarize - it looks like all actions to take here are in PCP itself. Is there any default redis.conf change we should make in the role, or shall I close this one out and we can continue discussions in the PCP issue trackers? Thanks. |
Afaics there is no change to
+1, I'll move this ticket over to the pcp repo. |
26GB pmproxy.log file on disk.
Filled with lines like:
The text was updated successfully, but these errors were encountered: