Save system logs in functional tests if server crashed#36885
Merged
Save system logs in functional tests if server crashed#36885
Conversation
qoega
approved these changes
May 3, 2022
Member
Author
|
Member
Author
|
Now it looks ok Anyway, I forgot to do another change |
azat
added a commit
to azat/ClickHouse
that referenced
this pull request
May 27, 2022
If 10 seconds will not be enough to finish the server, then
clickhouse-local (that goes after) cannot obtain the logs due to status
file will be locked, like in [1]:
Code: 76. DB::Exception: Cannot lock file /var/lib/clickhouse/status. Another server instance in same directory is already running. (CANNOT_OPEN_FILE)
[1]: https://s3.amazonaws.com/clickhouse-test-reports/35075/4a064e5b6f81136f2bf923d85001f25fa05d39ce/stateless_tests_flaky_check__address__actions_.html
So use proper wait via "clickhouse stop"
v2: Fix permissions pid file for replicated database servers
They do not use default, /var/run/clickhouse-server, that do not have
proper permissions.
Fixes: ClickHouse#36885
Signed-off-by: Azat Khuzhin <[email protected]>
azat
reviewed
Aug 3, 2023
| # for files >64MB, we want this files to be compressed explicitly | ||
| for table in query_log zookeeper_log trace_log transactions_info_log | ||
| do | ||
| clickhouse-client -q "select * from system.$table format TSVWithNamesAndTypes" | pigz > /test_output/$table.tsv.gz & |
Member
There was a problem hiding this comment.
The problem with using clickhouse-local here is that now it is not capable to save data from S3 storage, like the comment above this lines states. I guess clickhouse-local can be taught to use S3 (maybe simply using server config will be enough, though not sure)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changelog category (leave one):
Need these logs to debug #36610