Elasticsearch 7.10.1集群压测报告(4核16G*3,Intel)

2022-05-16 15:55:48 浏览数 (1)

说明

本文描述问题及解决方法同样适用于 腾讯云 Elasticsearch Service(ES)

另外使用到:腾讯云 云服务器(Cloud Virtual Machine,CVM)

本文延续上一篇 Elasticsearch压测工具esrally部署指南

本文另有延续:

Elasticsearch压力测试 - 云 社区 - 腾讯云 (tencent.com)

环境配置

Esrally客户端环境

  • 版本

Linux环境:Centos 7.9

Python:3.8.7

Pip:pip 20.2.3 from pip (python 3.8)

Java:openjdk version 1.8.0_302 (build 1.8.0_302-b08)

Git:2.7.5

Esrally:2.3.0

  • 配置

内存:32G

硬盘:SSD云硬盘 100GB

CPU个数:1

CPU核心数:16

Elasticsearch服务端环境

  • 版本

Linux环境:Centos 7.2

Java:openjdk version 11.0.9.1-ga (build 11.0.9.1-ga 1, mixed mode)

Elasticsearch版本:7.10.1(腾讯云 Elasticsearch Service 白金版)

  • 配置

节点数量:3

内存:16G

硬盘:SSD云硬盘 1TB

CPU个数:1

CPU核心数:4

CPU型号:Intel(R) Xeon(R) Platinum 8255C CPU @ 2.50GHz

背景

在大数据时代的今天,业务量越来越大,每天动辄都会产生上百GB、上TB的数据,所以拥有一个性能强劲的Elasticsearch集群就显得尤为重要。我们需要模拟大量网络日志、用户行为日志的读写动作,衡量各性能的指标,找出集群瓶颈所在,以确认我们需要怎样的硬件配置以及业务优化,才能满足现有的业务量,这就是我们在业务上线前所必要做的。

压测

esrally 相关术语及参数

Rally 是汽车拉力赛的意思,所以关于它里面术语也是跟汽车的拉力赛有关。

  • track: 即赛道的意思,这里指压测用到的样本数据和压测策略,使用 esrally list tracks 列出。rally 自带的 track 可在 https://github.com/elastic/rally-tracks 中查看,每个 track 的文件名中都存在 README.md 对压测的数据类型和参数做了详细的说明。如果没有指定 track, 则默认使用 geonames track 进行测试;
  • target-hosts:即远程elasticsearch的ip和端口,以ip:port的形式指定;
  • pipeline: 指一个压测流程,可以通过 esrally list pipeline 查看,其中有一个 benchmark-only 的流程,就是将 es 的管理交给用户来操作,rally 只用来做压测,如果你想针对已有的 es 进行压测,则使用该模式;
  • track-params:对默认的压测参数进行覆盖;
  • user-tag:本次压测的 tag 标记;
  • client-options:指定一些客户端连接选项,比如用户名和密码。

压测指令

代码语言:javascript复制
esrally race 
  --track=geonames 
  --target-hosts=10.0.10.4:9200 
  --pipeline=benchmark-only 
  --track-params="number_of_shards:3, number_of_replicas:1" 
  --user-tag="version:Intel_4C16G_1T*3" 
  --client-options="basic_auth_user:'elastic', basic_auth_password:'your_password'"

压测报告

压测指标

压测任务

压测结果

单位

Cumulative indexing time of primary shards

20.6193

min

Min cumulative indexing time across primary shards

0

min

Median cumulative indexing time across primary shards

0.004467

min

Max cumulative indexing time across primary shards

7.40908

min

Cumulative indexing throttle time of primary shards

0

min

Min cumulative indexing throttle time across primary shards

0

min

Median cumulative indexing throttle time across primary shards

0

min

Max cumulative indexing throttle time across primary shards

0

min

Cumulative merge time of primary shards

6.56155

min

Cumulative merge count of primary shards

154

Min cumulative merge time across primary shards

0

min

Median cumulative merge time across primary shards

0.002467

min

Max cumulative merge time across primary shards

2.34035

min

Cumulative merge throttle time of primary shards

0.72385

min

Min cumulative merge throttle time across primary shards

0

min

Median cumulative merge throttle time across primary shards

0

min

Max cumulative merge throttle time across primary shards

0.255317

min

Cumulative refresh time of primary shards

2.66617

min

Cumulative refresh count of primary shards

1381

Min cumulative refresh time across primary shards

0

min

Median cumulative refresh time across primary shards

0.02155

min

Max cumulative refresh time across primary shards

0.84375

min

Cumulative flush time of primary shards

0.357333

min

Cumulative flush count of primary shards

16

Min cumulative flush time across primary shards

0

min

Median cumulative flush time across primary shards

0.000483

min

Max cumulative flush time across primary shards

0.139483

min

Total Young Gen GC time

23.305

s

Total Young Gen GC count

2210

Total Old Gen GC time

0

s

Total Old Gen GC count

0

Store size

5.80512

GB

Translog size

0.016551

GB

Heap used for segments

0.894436

MB

Heap used for doc values

0.212818

MB

Heap used for terms

0.579559

MB

Heap used for norms

0.052124

MB

Heap used for points

0

MB

Heap used for stored fields

0.049934

MB

Segment count

103

Min Throughput

index-append

37192.1

docs/s

Mean Throughput

index-append

38562.3

docs/s

Median Throughput

index-append

38577.4

docs/s

Max Throughput

index-append

39329.3

docs/s

50th percentile latency

index-append

757.069

ms

90th percentile latency

index-append

1558.87

ms

99th percentile latency

index-append

3131.2

ms

99.9th percentile latency

index-append

4159.98

ms

100th percentile latency

index-append

4638.15

ms

50th percentile service time

index-append

757.069

ms

90th percentile service time

index-append

1558.87

ms

99th percentile service time

index-append

3131.2

ms

99.9th percentile service time

index-append

4159.98

ms

100th percentile service time

index-append

4638.15

ms

error rate

index-append

0

%

Min Throughput

index-stats

88.84

ops/s

Mean Throughput

index-stats

89.31

ops/s

Median Throughput

index-stats

89.37

ops/s

Max Throughput

index-stats

89.57

ops/s

50th percentile latency

index-stats

3.74153

ms

90th percentile latency

index-stats

4.26026

ms

99th percentile latency

index-stats

5.06623

ms

99.9th percentile latency

index-stats

10.9303

ms

100th percentile latency

index-stats

11.3278

ms

50th percentile service time

index-stats

2.98002

ms

90th percentile service time

index-stats

3.3412

ms

99th percentile service time

index-stats

4.48545

ms

99.9th percentile service time

index-stats

10.0526

ms

100th percentile service time

index-stats

10.456

ms

error rate

index-stats

0

%

Min Throughput

node-stats

89.96

ops/s

Mean Throughput

node-stats

89.98

ops/s

Median Throughput

node-stats

89.98

ops/s

Max Throughput

node-stats

89.99

ops/s

50th percentile latency

node-stats

4.20336

ms

90th percentile latency

node-stats

4.86076

ms

99th percentile latency

node-stats

7.46976

ms

99.9th percentile latency

node-stats

23.3641

ms

100th percentile latency

node-stats

26.0743

ms

50th percentile service time

node-stats

3.44984

ms

90th percentile service time

node-stats

3.98803

ms

99th percentile service time

node-stats

5.88917

ms

99.9th percentile service time

node-stats

18.5987

ms

100th percentile service time

node-stats

19.6244

ms

error rate

node-stats

0

%

Min Throughput

default

50.01

ops/s

Mean Throughput

default

50.02

ops/s

Median Throughput

default

50.02

ops/s

Max Throughput

default

50.03

ops/s

50th percentile latency

default

4.56919

ms

90th percentile latency

default

5.15531

ms

99th percentile latency

default

6.27243

ms

99.9th percentile latency

default

12.4007

ms

100th percentile latency

default

22.4557

ms

50th percentile service time

default

3.86202

ms

90th percentile service time

default

4.26302

ms

99th percentile service time

default

5.09573

ms

99.9th percentile service time

default

12.0892

ms

100th percentile service time

default

22.0959

ms

error rate

default

0

%

Min Throughput

term

99.87

ops/s

Mean Throughput

term

99.92

ops/s

Median Throughput

term

99.92

ops/s

Max Throughput

term

99.95

ops/s

50th percentile latency

term

3.6805

ms

90th percentile latency

term

4.20496

ms

99th percentile latency

term

4.8078

ms

99.9th percentile latency

term

6.21686

ms

100th percentile latency

term

7.67519

ms

50th percentile service time

term

2.95697

ms

90th percentile service time

term

3.34813

ms

99th percentile service time

term

3.7931

ms

99.9th percentile service time

term

5.68276

ms

100th percentile service time

term

7.39664

ms

error rate

term

0

%

Min Throughput

phrase

109.74

ops/s

Mean Throughput

phrase

109.84

ops/s

Median Throughput

phrase

109.86

ops/s

Max Throughput

phrase

109.9

ops/s

50th percentile latency

phrase

4.28877

ms

90th percentile latency

phrase

5.11524

ms

99th percentile latency

phrase

42.0841

ms

99.9th percentile latency

phrase

69.3999

ms

100th percentile latency

phrase

74.596

ms

50th percentile service time

phrase

3.56652

ms

90th percentile service time

phrase

4.15267

ms

99th percentile service time

phrase

6.57685

ms

99.9th percentile service time

phrase

46.4388

ms

100th percentile service time

phrase

73.9546

ms

error rate

phrase

0

%

Min Throughput

country_agg_uncached

2.98

ops/s

Mean Throughput

country_agg_uncached

2.99

ops/s

Median Throughput

country_agg_uncached

2.99

ops/s

Max Throughput

country_agg_uncached

2.99

ops/s

50th percentile latency

country_agg_uncached

394.449

ms

90th percentile latency

country_agg_uncached

599.613

ms

99th percentile latency

country_agg_uncached

710.759

ms

100th percentile latency

country_agg_uncached

726.641

ms

50th percentile service time

country_agg_uncached

273.89

ms

90th percentile service time

country_agg_uncached

418.28

ms

99th percentile service time

country_agg_uncached

422.41

ms

100th percentile service time

country_agg_uncached

424.37

ms

error rate

country_agg_uncached

0

%

Min Throughput

country_agg_cached

96.28

ops/s

Mean Throughput

country_agg_cached

97.26

ops/s

Median Throughput

country_agg_cached

97.35

ops/s

Max Throughput

country_agg_cached

97.95

ops/s

50th percentile latency

country_agg_cached

2.55901

ms

90th percentile latency

country_agg_cached

3.09923

ms

99th percentile latency

country_agg_cached

3.97148

ms

99.9th percentile latency

country_agg_cached

7.76284

ms

100th percentile latency

country_agg_cached

14.3596

ms

50th percentile service time

country_agg_cached

1.8663

ms

90th percentile service time

country_agg_cached

2.14042

ms

99th percentile service time

country_agg_cached

2.8934

ms

99.9th percentile service time

country_agg_cached

6.04843

ms

100th percentile service time

country_agg_cached

13.7749

ms

error rate

country_agg_cached

0

%

Min Throughput

scroll

20.02

pages/s

Mean Throughput

scroll

20.03

pages/s

Median Throughput

scroll

20.03

pages/s

Max Throughput

scroll

20.04

pages/s

50th percentile latency

scroll

639.647

ms

90th percentile latency

scroll

654.51

ms

99th percentile latency

scroll

670.697

ms

100th percentile latency

scroll

671.465

ms

50th percentile service time

scroll

638.284

ms

90th percentile service time

scroll

652.531

ms

99th percentile service time

scroll

669.014

ms

100th percentile service time

scroll

669.801

ms

error rate

scroll

0

%

Min Throughput

expression

1.49

ops/s

Mean Throughput

expression

1.5

ops/s

Median Throughput

expression

1.5

ops/s

Max Throughput

expression

1.5

ops/s

50th percentile latency

expression

586.499

ms

90th percentile latency

expression

831.2

ms

99th percentile latency

expression

995.585

ms

100th percentile latency

expression

1158.31

ms

50th percentile service time

expression

503.344

ms

90th percentile service time

expression

829.329

ms

99th percentile service time

expression

835.81

ms

100th percentile service time

expression

840.604

ms

error rate

expression

0

%

Min Throughput

painless_static

1.33

ops/s

Mean Throughput

painless_static

1.33

ops/s

Median Throughput

painless_static

1.33

ops/s

Max Throughput

painless_static

1.34

ops/s

50th percentile latency

painless_static

8863.94

ms

90th percentile latency

painless_static

11195.4

ms

99th percentile latency

painless_static

11497.7

ms

100th percentile latency

painless_static

11565.9

ms

50th percentile service time

painless_static

677.084

ms

90th percentile service time

painless_static

1007.67

ms

99th percentile service time

painless_static

1017.51

ms

100th percentile service time

painless_static

1019.52

ms

error rate

painless_static

0

%

Min Throughput

painless_dynamic

1.34

ops/s

Mean Throughput

painless_dynamic

1.34

ops/s

Median Throughput

painless_dynamic

1.34

ops/s

Max Throughput

painless_dynamic

1.35

ops/s

50th percentile latency

painless_dynamic

7716.2

ms

90th percentile latency

painless_dynamic

9965.18

ms

99th percentile latency

painless_dynamic

10441.3

ms

100th percentile latency

painless_dynamic

10492.5

ms

50th percentile service time

painless_dynamic

661.345

ms

90th percentile service time

painless_dynamic

1037.11

ms

99th percentile service time

painless_dynamic

1043.82

ms

100th percentile service time

painless_dynamic

1047.61

ms

error rate

painless_dynamic

0

%

Min Throughput

decay_geo_gauss_function_score

1

ops/s

Mean Throughput

decay_geo_gauss_function_score

1

ops/s

Median Throughput

decay_geo_gauss_function_score

1

ops/s

Max Throughput

decay_geo_gauss_function_score

1

ops/s

50th percentile latency

decay_geo_gauss_function_score

648.712

ms

90th percentile latency

decay_geo_gauss_function_score

857.975

ms

99th percentile latency

decay_geo_gauss_function_score

865.561

ms

100th percentile latency

decay_geo_gauss_function_score

900.39

ms

50th percentile service time

decay_geo_gauss_function_score

647.561

ms

90th percentile service time

decay_geo_gauss_function_score

856.9

ms

99th percentile service time

decay_geo_gauss_function_score

864.853

ms

100th percentile service time

decay_geo_gauss_function_score

899.441

ms

error rate

decay_geo_gauss_function_score

0

%

Min Throughput

decay_geo_gauss_script_score

1

ops/s

Mean Throughput

decay_geo_gauss_script_score

1

ops/s

Median Throughput

decay_geo_gauss_script_score

1

ops/s

Max Throughput

decay_geo_gauss_script_score

1

ops/s

50th percentile latency

decay_geo_gauss_script_score

675.759

ms

90th percentile latency

decay_geo_gauss_script_score

858.931

ms

99th percentile latency

decay_geo_gauss_script_score

867.416

ms

100th percentile latency

decay_geo_gauss_script_score

867.762

ms

50th percentile service time

decay_geo_gauss_script_score

673.839

ms

90th percentile service time

decay_geo_gauss_script_score

858.017

ms

99th percentile service time

decay_geo_gauss_script_score

865.997

ms

100th percentile service time

decay_geo_gauss_script_score

866.189

ms

error rate

decay_geo_gauss_script_score

0

%

Min Throughput

field_value_function_score

1.5

ops/s

Mean Throughput

field_value_function_score

1.5

ops/s

Median Throughput

field_value_function_score

1.5

ops/s

Max Throughput

field_value_function_score

1.5

ops/s

50th percentile latency

field_value_function_score

244.946

ms

90th percentile latency

field_value_function_score

344.916

ms

99th percentile latency

field_value_function_score

352.398

ms

100th percentile latency

field_value_function_score

353.123

ms

50th percentile service time

field_value_function_score

243.922

ms

90th percentile service time

field_value_function_score

343.923

ms

99th percentile service time

field_value_function_score

351.699

ms

100th percentile service time

field_value_function_score

352.372

ms

error rate

field_value_function_score

0

%

Min Throughput

field_value_script_score

1.5

ops/s

Mean Throughput

field_value_script_score

1.5

ops/s

Median Throughput

field_value_script_score

1.5

ops/s

Max Throughput

field_value_script_score

1.5

ops/s

50th percentile latency

field_value_script_score

336.508

ms

90th percentile latency

field_value_script_score

524.796

ms

99th percentile latency

field_value_script_score

525.673

ms

100th percentile latency

field_value_script_score

534.845

ms

50th percentile service time

field_value_script_score

335.238

ms

90th percentile service time

field_value_script_score

523.149

ms

99th percentile service time

field_value_script_score

524.684

ms

100th percentile service time

field_value_script_score

533.281

ms

error rate

field_value_script_score

0

%

Min Throughput

large_terms

0.83

ops/s

Mean Throughput

large_terms

0.83

ops/s

Median Throughput

large_terms

0.83

ops/s

Max Throughput

large_terms

0.84

ops/s

50th percentile latency

large_terms

73647.2

ms

90th percentile latency

large_terms

84331.5

ms

99th percentile latency

large_terms

87455.4

ms

100th percentile latency

large_terms

87763.8

ms

50th percentile service time

large_terms

1100

ms

90th percentile service time

large_terms

1595.42

ms

99th percentile service time

large_terms

1740.93

ms

100th percentile service time

large_terms

1749.53

ms

error rate

large_terms

0

%

Min Throughput

large_filtered_terms

0.82

ops/s

Mean Throughput

large_filtered_terms

0.82

ops/s

Median Throughput

large_filtered_terms

0.82

ops/s

Max Throughput

large_filtered_terms

0.82

ops/s

50th percentile latency

large_filtered_terms

78609.8

ms

90th percentile latency

large_filtered_terms

90167.3

ms

99th percentile latency

large_filtered_terms

92686.3

ms

100th percentile latency

large_filtered_terms

92819.9

ms

50th percentile service time

large_filtered_terms

1068.04

ms

90th percentile service time

large_filtered_terms

1596.99

ms

99th percentile service time

large_filtered_terms

1726.52

ms

100th percentile service time

large_filtered_terms

1752.59

ms

error rate

large_filtered_terms

0

%

Min Throughput

large_prohibited_terms

0.89

ops/s

Mean Throughput

large_prohibited_terms

0.9

ops/s

Median Throughput

large_prohibited_terms

0.9

ops/s

Max Throughput

large_prohibited_terms

0.91

ops/s

50th percentile latency

large_prohibited_terms

51245.5

ms

90th percentile latency

large_prohibited_terms

61183.4

ms

99th percentile latency

large_prohibited_terms

63242.5

ms

100th percentile latency

large_prohibited_terms

63721.2

ms

50th percentile service time

large_prohibited_terms

1083.46

ms

90th percentile service time

large_prohibited_terms

1384.08

ms

99th percentile service time

large_prohibited_terms

1684.25

ms

100th percentile service time

large_prohibited_terms

1716.78

ms

error rate

large_prohibited_terms

0

%

Min Throughput

desc_sort_population

1.5

ops/s

Mean Throughput

desc_sort_population

1.5

ops/s

Median Throughput

desc_sort_population

1.5

ops/s

Max Throughput

desc_sort_population

1.5

ops/s

50th percentile latency

desc_sort_population

108.037

ms

90th percentile latency

desc_sort_population

169.415

ms

99th percentile latency

desc_sort_population

173.849

ms

100th percentile latency

desc_sort_population

174.702

ms

50th percentile service time

desc_sort_population

106.235

ms

90th percentile service time

desc_sort_population

168.255

ms

99th percentile service time

desc_sort_population

172.249

ms

100th percentile service time

desc_sort_population

172.439

ms

error rate

desc_sort_population

0

%

Min Throughput

asc_sort_population

1.5

ops/s

Mean Throughput

asc_sort_population

1.5

ops/s

Median Throughput

asc_sort_population

1.5

ops/s

Max Throughput

asc_sort_population

1.51

ops/s

50th percentile latency

asc_sort_population

112.151

ms

90th percentile latency

asc_sort_population

187.041

ms

99th percentile latency

asc_sort_population

190.23

ms

100th percentile latency

asc_sort_population

190.757

ms

50th percentile service time

asc_sort_population

111.163

ms

90th percentile service time

asc_sort_population

185.456

ms

99th percentile service time

asc_sort_population

189.457

ms

100th percentile service time

asc_sort_population

189.604

ms

error rate

asc_sort_population

0

%

Min Throughput

asc_sort_with_after_population

1.5

ops/s

Mean Throughput

asc_sort_with_after_population

1.5

ops/s

Median Throughput

asc_sort_with_after_population

1.5

ops/s

Max Throughput

asc_sort_with_after_population

1.5

ops/s

50th percentile latency

asc_sort_with_after_population

166.955

ms

90th percentile latency

asc_sort_with_after_population

299.339

ms

99th percentile latency

asc_sort_with_after_population

303.174

ms

100th percentile latency

asc_sort_with_after_population

304.096

ms

50th percentile service time

asc_sort_with_after_population

166.094

ms

90th percentile service time

asc_sort_with_after_population

298.16

ms

99th percentile service time

asc_sort_with_after_population

301.707

ms

100th percentile service time

asc_sort_with_after_population

302.899

ms

error rate

asc_sort_with_after_population

0

%

Min Throughput

desc_sort_geonameid

6

ops/s

Mean Throughput

desc_sort_geonameid

6

ops/s

Median Throughput

desc_sort_geonameid

6

ops/s

Max Throughput

desc_sort_geonameid

6

ops/s

50th percentile latency

desc_sort_geonameid

12.1517

ms

90th percentile latency

desc_sort_geonameid

13.2045

ms

99th percentile latency

desc_sort_geonameid

13.6046

ms

100th percentile latency

desc_sort_geonameid

13.9144

ms

50th percentile service time

desc_sort_geonameid

11.6082

ms

90th percentile service time

desc_sort_geonameid

12.2822

ms

99th percentile service time

desc_sort_geonameid

12.4863

ms

100th percentile service time

desc_sort_geonameid

13.133

ms

error rate

desc_sort_geonameid

0

%

Min Throughput

desc_sort_with_after_geonameid

5.62

ops/s

Mean Throughput

desc_sort_with_after_geonameid

5.65

ops/s

Median Throughput

desc_sort_with_after_geonameid

5.65

ops/s

Max Throughput

desc_sort_with_after_geonameid

5.69

ops/s

50th percentile latency

desc_sort_with_after_geonameid

2714.69

ms

90th percentile latency

desc_sort_with_after_geonameid

2848.8

ms

99th percentile latency

desc_sort_with_after_geonameid

2957.33

ms

100th percentile latency

desc_sort_with_after_geonameid

2987.48

ms

50th percentile service time

desc_sort_with_after_geonameid

142.747

ms

90th percentile service time

desc_sort_with_after_geonameid

243.951

ms

99th percentile service time

desc_sort_with_after_geonameid

249.702

ms

100th percentile service time

desc_sort_with_after_geonameid

249.824

ms

error rate

desc_sort_with_after_geonameid

0

%

Min Throughput

asc_sort_geonameid

6.02

ops/s

Mean Throughput

asc_sort_geonameid

6.02

ops/s

Median Throughput

asc_sort_geonameid

6.02

ops/s

Max Throughput

asc_sort_geonameid

6.03

ops/s

50th percentile latency

asc_sort_geonameid

6.19295

ms

90th percentile latency

asc_sort_geonameid

6.85094

ms

99th percentile latency

asc_sort_geonameid

8.11223

ms

100th percentile latency

asc_sort_geonameid

8.7874

ms

50th percentile service time

asc_sort_geonameid

5.51636

ms

90th percentile service time

asc_sort_geonameid

5.82107

ms

99th percentile service time

asc_sort_geonameid

7.5506

ms

100th percentile service time

asc_sort_geonameid

7.88462

ms

error rate

asc_sort_geonameid

0

%

Min Throughput

asc_sort_with_after_geonameid

5.97

ops/s

Mean Throughput

asc_sort_with_after_geonameid

5.98

ops/s

Median Throughput

asc_sort_with_after_geonameid

5.98

ops/s

Max Throughput

asc_sort_with_after_geonameid

5.99

ops/s

50th percentile latency

asc_sort_with_after_geonameid

215.845

ms

90th percentile latency

asc_sort_with_after_geonameid

302.616

ms

99th percentile latency

asc_sort_with_after_geonameid

392.432

ms

100th percentile latency

asc_sort_with_after_geonameid

434.061

ms

50th percentile service time

asc_sort_with_after_geonameid

127.588

ms

90th percentile service time

asc_sort_with_after_geonameid

214.525

ms

99th percentile service time

asc_sort_with_after_geonameid

216.275

ms

100th percentile service time

asc_sort_with_after_geonameid

217.393

ms

error rate

asc_sort_with_after_geonameid

0

%

0 人点赞