Uneven CPU Distribution in TiDB Server

Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.

Original topic: tidb server cpu分布不均衡

| username: johnnnyli

How is resource scheduling handled when TiDB is computing? Currently, after submitting SQL, I found that only the CPU usage of the TiDB server node where the SQL was submitted is close to 90%, while the usage of other nodes is very low. Can anyone share their experience?

| username: forever | Original post link

What is used for load balancing between TiDB servers? TiDB itself does not have scheduling between TiDB servers. For example, if a large SQL or multiple large SQLs are running on a particular server, you will see the situation you described.

| username: johnnnyli | Original post link

Does it mean that when a single SQL requires a lot of resources, it is not possible to schedule resources from other nodes?

| username: johnnnyli | Original post link

Adding load balancing on top of the TiDB server can only address the request pressure on the cluster from multiple requests, but what about when a single request has too much pressure?

| username: forever | Original post link

No, the TiDB server is stateless, does not store data, and does not share it.

| username: johnnnyli | Original post link

Okay, got it, thank you.

| username: forever | Original post link

You can use several instances for OLTP applications and separate instances for OLAP applications, so they do not affect each other; and the separated instances can also be roughly balanced.

| username: johnnnyli | Original post link

Are you referring to the TiDB server?

| username: forever | Original post link

Yes, TiDB server.

| username: johnnnyli | Original post link

Got it.

| username: system | Original post link

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.