-
Notifications
You must be signed in to change notification settings - Fork 826
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
Logging #621
Comments
Hi, Those are not PostgreSQL, but Patroni logs, so changing PostgreSQL parameters won't affect them. Why do you think they are 'unnecessary'? Patroni reports every iteration of the event loop its role and who is the leader. Knowing that is important in order to understand, for instance, why did the failover happen. You can mute the INFO messages from the event loop by setting the level in a We may also provide some way of controlling log levels in the future. Feel free to contribute a PR if you are interested. |
I've submitted #622 to make log level configurable using environment vars, but as these are at INFO level it'd still require hacking ha.py to mute the event loop messages. |
Alexey, thanks for answer. Because system work stable, without reboot and changes, but they write to syslog every second. I really need only first message who i master and messanges when patroni change master, no more |
@mrquokka feel free to submit a PR. I think it makes sense to have a group of N messages (so that Patroni says 'Leader with a lock (repeated N times)'. @antineutron I think your PR needs to change how the loggers are spawned, so that there is a single place to set the logging level. Also, we might want to set this parameter in the configuration file rather than via the environment variables (and change it with a reload of Patroni without stopping its operations). |
[Repeated 100 times] : Lock owner: postgresql0; I am postgresql0; no action; i'm a leader with the lock In one string |
Hi there, can someone help to clear unnecessary logs, such us
I tried to change postgresql parameters, such us:
and
init.py on source:
logging.basicConfig(format=logformat, level=logging.WARNING)
But nothing changes
The text was updated successfully, but these errors were encountered: