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

Health Checks #63

Open
ghjm opened this issue Dec 10, 2021 · 0 comments
Open

Health Checks #63

ghjm opened this issue Dec 10, 2021 · 0 comments

Comments

@ghjm
Copy link
Contributor

ghjm commented Dec 10, 2021

Use the operator's credentials to connect to the ClickHouse instance and run health checks:

  • Access point is available (use chi level service)
  • Distributed query check:
    SELECT count() FROM cluster('all-sharded', cluster('all-sharded', system.one))
  • Zookeeper check -- run only if zookeeper is a part of CHI spec.configuration:
    SELECT count() FROM system.zookeeper WHERE path = '/'
  • No readonly replicas:
    SELECT max(value) FROM cluster('{cluster}', system.metrics) WHERE metric = 'ReadonlyReplica'
  • No delayed inserts:
    SELECT value FROM system.metrics WHERE metric = 'DelayedInserts'
  • Healthy schema: MaxPartCountForPartition: >150 yellow, >300 red:
    select value from system.asynchronous_metrics where metric='MaxPartCountForPartition'

Provide some kind of warning if the health checks are failing.

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

No branches or pull requests

1 participant