Locust性能测试III多进程压测

Locust支持在同一台机器上开启多进程执行压测,以Master和Slave的模式,各Slave将最终结果呈现在Master Web管理页面。
locust -f locust_files/my_locust_file.py --master --host=http://example.com
locust -f locust_files/my_locust_file.py --slave --host=http://example.com

启动Master

在命令行执行命令locust -f locust_files/my_locust_file.py --master --host=http://example.com

启动Slave

再启动一个新的命令行进程,执行命令locust -f locust_files/my_locust_file.py --slave --host=http://example.com
如果需要多个Slave,那么就再启动新的命令行

Master 页面管理

在这里插入图片描述
在这里插入图片描述

发布了162 篇原创文章 · 获赞 42 · 访问量 2万+

猜你喜欢

转载自blog.csdn.net/dawei_yang000000/article/details/102955622