1、运行esrally 高级配置模式
高级配置模式和普通模式的区别:普通模式只需要配置jdk的环境变量路径。
而高级模式,需要配置:当前本机已安装elasticsearch的监听端口以及ES配置的主机名称。
高级配置模式详情:
[elasticsearch@laoyang root]$ esrally configure --advanced-config
____ ____
/ __ \____ _/ / /_ __
/ /_/ / __ `/ / / / / /
/ _, _/ /_/ / / / /_/ /
/_/ |_|\__,_/_/_/\__, /
/____/
Running advanced configuration. You can get additional help at:
https://esrally.readthedocs.io/en/latest/configuration.html
WARNING: Will overwrite existing config file at [/home/elasticsearch/.rally/rally.ini]
[✓] Autodetecting available third-party software
git : [✓]
gradle : [✓]
JDK 8 : [✕] (You cannot benchmark Elasticsearch 5.x without a JDK 8 installation)
[✓] Setting up benchmark data directory in [/home/elasticsearch/.rally/benchmarks] (needs several GB).
Enter your Elasticsearch project directory: [default: '/home/elasticsearch/.rally/benchmarks/src']:
Using default value '/home/elasticsearch/.rally/benchmarks/src'
Enter the JDK 8 root directory:: /opt/jdk1.8.0_91
Enter a descriptive name for this benchmark environment (ASCII, no spaces): local
Enter the host name of the ES metrics store [default: 'localhost']: laoyang
#elasticsearch的监听端口
Enter the port of the ES metrics store: 9200
Use secure connection (True, False) [default: 'False']:
Using default value 'False'
Username for basic authentication (empty if not needed) [default: '']:
Using default value ''
Password for basic authentication (empty if not needed) [default: '']:
Using default value ''
[✓] Configuration successfully written to [/home/elasticsearch/.rally/rally.ini]. Happy benchmarking!
To benchmark the currently checked out version of Elasticsearch with the default benchmark run:
esrally
For help, type esrally --help or see the user documentation at https://esrally.readthedocs.io
You have new mail in /var/spool/mail/root
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
2、运行esrally
[elasticsearch@laoyang root]$ esrally
____ ____
/ __ \____ _/ / /_ __
/ /_/ / __ `/ / / / / /
/ _, _/ /_/ / / / /_/ /
/_/ |_|\__,_/_/_/\__, /
/____/
1
2
3
4
5
6
7
8
3、在head插件前端和kibana前端看输出结果。
head插件会显示:新增的索引:rally-2016.
kibana配置参考:
https://elasticsearch-benchmark-analytics.elastic.co/app/kibana#/visualize/edit/Index-disk-usage (官网esrally性能测试)
下图信息,如果每天运行一次性能测试,就能够跑出性能曲线。(横轴:日期,纵轴:性能指标)
4. 细节与rally源码作者讨论如下
https://discuss.elastic.co/t/the-detail-meaning-of-esrally-final-score/57454/10045