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

30s or 1min slow query on low load cluster #32500

Closed
tiancaiamao opened this issue Feb 21, 2022 · 3 comments
Closed

30s or 1min slow query on low load cluster #32500

tiancaiamao opened this issue Feb 21, 2022 · 3 comments
Labels
affects-5.1 This bug affects 5.1.x versions. component/tikv-client fixes-5.1.2 fixes-5.2.0 may-affects-4.0 This bug maybe affects 4.0.x versions. may-affects-5.0 This bug maybe affects 5.0.x versions. severity/major type/bug The issue is confirmed as a bug.

Comments

@tiancaiamao
Copy link
Contributor

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

Found in our customer's environment

In the tidb log, "recycle idle connection" can be found.
The cluster is not busy, but sometime it get slow query even on point get operation.
Typically, the slow query takes 30s ... (which is the timeout retry duration)

Maybe in some cases, the latency of the load schema is also high from grafana metrics.

2. What did you expect to see? (Required)

No unexpected slow query when the cluster is not busy.

3. What did you see instead (Required)

"recycle idle connection" log in TiDB, and also some unexpected slow query...

4. What is your TiDB version? (Required)

release-5.1

@tiancaiamao tiancaiamao added type/bug The issue is confirmed as a bug. affects-5.1 This bug affects 5.1.x versions. labels Feb 21, 2022
@tiancaiamao
Copy link
Contributor Author

tiancaiamao commented Feb 21, 2022

Fixed in 5.2.0
tikv/client-go#292

@tiancaiamao
Copy link
Contributor Author

There are currently two known cases the bug may trigger:

  • In a low load cluster, where "recycle idle connection" can be observed
  • In a cluster with TiFlash, and during the TiFlash reboot, the bug may cause TiDB qps drop to 0

@ti-chi-bot ti-chi-bot added may-affects-4.0 This bug maybe affects 4.0.x versions. may-affects-5.0 This bug maybe affects 5.0.x versions. may-affects-5.2 This bug maybe affects 5.2.x versions. may-affects-5.3 This bug maybe affects 5.3.x versions. may-affects-5.4 This bug maybe affects 5.4.x versions. labels Feb 21, 2022
@tiancaiamao tiancaiamao added fixes-5.2.0 and removed affects-6.0 may-affects-5.3 This bug maybe affects 5.3.x versions. may-affects-5.4 This bug maybe affects 5.4.x versions. may-affects-5.2 This bug maybe affects 5.2.x versions. labels Mar 24, 2022
@windtalker
Copy link
Contributor

@tiancaiamao if it is already fixed since 5.2.0, can we close this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
affects-5.1 This bug affects 5.1.x versions. component/tikv-client fixes-5.1.2 fixes-5.2.0 may-affects-4.0 This bug maybe affects 4.0.x versions. may-affects-5.0 This bug maybe affects 5.0.x versions. severity/major type/bug The issue is confirmed as a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants