k8s上部署tidb,单表10亿数据跑sysbench oltp_read_only 性能比较差

麻烦帮忙指导一下怎么定位

sysbench --config-file=config oltp_read_only --tables=1 --table-size=1000000000 run
sysbench 1.0.20 (using bundled LuaJIT 2.1.0-beta2)

Running the test with following options:
Number of threads: 16
Report intermediate results every 10 second(s)
Initializing random number generator from current time

Initializing worker threads…

Threads started!

[ 10s ] thds: 16 tps: 380.43 qps: 6099.34 (r/w/o: 5336.97/0.00/762.37) lat (ms,95%): 45.79 err/s: 0.00 reconn/s: 0.00
[ 20s ] thds: 16 tps: 326.00 qps: 5215.27 (r/w/o: 4563.36/0.00/651.91) lat (ms,95%): 47.47 err/s: 0.00 reconn/s: 0.00
[ 30s ] thds: 16 tps: 386.70 qps: 6191.44 (r/w/o: 5417.95/0.00/773.49) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 40s ] thds: 16 tps: 385.90 qps: 6173.06 (r/w/o: 5401.15/0.00/771.91) lat (ms,95%): 44.98 err/s: 0.00 reconn/s: 0.00
[ 50s ] thds: 16 tps: 388.40 qps: 6212.09 (r/w/o: 5435.29/0.00/776.80) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 60s ] thds: 16 tps: 389.40 qps: 6231.15 (r/w/o: 5452.65/0.00/778.51) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 70s ] thds: 16 tps: 388.60 qps: 6214.13 (r/w/o: 5436.74/0.00/777.39) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 80s ] thds: 16 tps: 389.20 qps: 6229.45 (r/w/o: 5450.95/0.00/778.51) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 90s ] thds: 16 tps: 390.30 qps: 6244.37 (r/w/o: 5463.97/0.00/780.40) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 100s ] thds: 16 tps: 389.90 qps: 6240.69 (r/w/o: 5460.79/0.00/779.90) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 110s ] thds: 16 tps: 387.80 qps: 6201.62 (r/w/o: 5426.12/0.00/775.50) lat (ms,95%): 44.98 err/s: 0.00 reconn/s: 0.00
[ 120s ] thds: 16 tps: 389.60 qps: 6235.30 (r/w/o: 5455.90/0.00/779.40) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 130s ] thds: 16 tps: 390.11 qps: 6242.91 (r/w/o: 5462.69/0.00/780.21) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 140s ] thds: 16 tps: 389.89 qps: 6236.31 (r/w/o: 5456.72/0.00/779.59) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 150s ] thds: 16 tps: 387.60 qps: 6200.20 (r/w/o: 5424.80/0.00/775.40) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 160s ] thds: 16 tps: 387.50 qps: 6202.59 (r/w/o: 5427.59/0.00/775.00) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 170s ] thds: 16 tps: 387.30 qps: 6196.78 (r/w/o: 5422.18/0.00/774.60) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 180s ] thds: 16 tps: 388.30 qps: 6213.52 (r/w/o: 5436.92/0.00/776.60) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 190s ] thds: 16 tps: 389.70 qps: 6234.12 (r/w/o: 5454.82/0.00/779.30) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 200s ] thds: 16 tps: 388.20 qps: 6213.45 (r/w/o: 5436.95/0.00/776.51) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 210s ] thds: 16 tps: 389.50 qps: 6228.23 (r/w/o: 5449.44/0.00/778.79) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 220s ] thds: 16 tps: 388.30 qps: 6215.42 (r/w/o: 5438.62/0.00/776.80) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 230s ] thds: 16 tps: 391.20 qps: 6257.20 (r/w/o: 5474.90/0.00/782.30) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 240s ] thds: 16 tps: 390.60 qps: 6249.64 (r/w/o: 5468.43/0.00/781.20) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 250s ] thds: 16 tps: 391.10 qps: 6258.46 (r/w/o: 5476.36/0.00/782.09) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 260s ] thds: 16 tps: 389.00 qps: 6222.80 (r/w/o: 5444.60/0.00/778.20) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 270s ] thds: 16 tps: 387.30 qps: 6198.09 (r/w/o: 5423.49/0.00/774.60) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 280s ] thds: 16 tps: 390.30 qps: 6243.91 (r/w/o: 5463.51/0.00/780.40) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 290s ] thds: 16 tps: 389.20 qps: 6230.35 (r/w/o: 5451.75/0.00/778.61) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
[ 300s ] thds: 16 tps: 389.30 qps: 6227.65 (r/w/o: 5449.16/0.00/778.49) lat (ms,95%): 44.17 err/s: 0.00 reconn/s: 0.00
SQL statistics:
queries performed:
read: 1623762
write: 0
other: 231966
total: 1855728
transactions: 115983 (386.55 per sec.)
queries: 1855728 (6184.85 per sec.)
ignored errors: 0 (0.00 per sec.)
reconnects: 0 (0.00 per sec.)

General statistics:
total time: 300.0425s
total number of events: 115983

Latency (ms):
min: 35.36
avg: 41.38
max: 883.08
95th percentile: 44.17
sum: 4799943.34

Threads fairness:
events (avg/stddev): 7248.9375/37.85
execution time (avg/stddev): 299.9965/0.01

diagnosis.pdf (616.9 KB)

可以参考文档排查下读流程

感谢感谢。

有疑问我们在交流

此话题已在最后回复的 1 分钟后被自动关闭。不再允许新回复。