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 support for logging to stdout/stderr #2241
Comments
|
Remove the following elements from your config: And add (to section) |
|
And simpler redefining logger config keys: |
|
That helped some but didn't fully work for me. After applying these logger settings: I saw this in my error log:
I started to see some error logs in the console output, but it also continued to write some logs (but not all) to It also continued to write to |
|
Yes, better to restart server. |
|
After restarting, logs appear to be only routing to stdout. Thanks for your help! |
|
Thank you for the workaround above. I developed a CH log parser with multi line parsing of CH logs, which works also for containers. I wonder why these logger settings are not enabled by default in the docker specific configuration: https://github.com/yandex/ClickHouse/blob/master/docker/server/docker_related_config.xml Is there a plan to enable console logs by default - many logging tools collect logs from container console output. |
|
Corresponding to https://clickhouse.tech/docs/en/operations/server-configuration-parameters/settings/ this is not working anymore UPD Hacky workaround: <log>/proc/self/fd/1</log>
<errorlog>/proc/self/fd/2</errorlog>But it would be better if logging to stdout&stderr will be simpler than this. |
|
The following worked for me with ClickHouse v21.7: <logger>
<console>true</console>
<log remove="remove"/>
<errorlog remove="remove"/>
</logger> |
We are running ClickHouse inside Kubernetes, which prefers all logs be written to stdout and stderr. It would be great to have that as a supported
loggersetting that would just write out logs and not handle any log rotation.The text was updated successfully, but these errors were encountered: