“停止”停止“停止”说明有多个分布式模式的工人
从主节点的Web控制台单击“停止”负载测试后观察到问题。 “停止”状态更改为“停止”状态,并挂在那里而无需达到“停止”状态。当只有1名工人时,它可以正确地“停止”状态。.我不得不重新启动蝗虫大师以重新启动负载测试,以悬挂在“停止”状态时。当我有一个以上的工人时,问题重复。
我首先在AWS Fargate容器上运行Master和Workers时,首先经历了这个问题。令人信服的是,在按下停止按钮后,没有错误的主和工人容器记录。只需单个工具容器,停止状态就可以正确地移至Web控制台主机上的“停止”。有1个以上的工人引起此问题。
后来,我可以在没有Docker的情况下在本地机器上复制此问题。
当我从本地MacBook本身中运行Locust Master和2名工人时,我正在遇到这个问题。 单击“停止”后没有错误。对于1名工人,它可以正常工作,并移至“停止”状态。
如何在本地MacBook中
- 从一个终端中启动Locust Master,其中命令
rocust -f my_locustfile.py-master
- 启动2个蝗虫工人,来自另外2个终端,命令
rocust -locust -f my_locustfile.py.py-worker。
(在此处是本地运行时,忽略了“ - 主机主机”参数。在AWS Fargate设置中,我们有该参数)
之后)在此主Web控制台之后=“ nofollow noreferrer”> http://0.0.0.0.0:8089/ )显示了2个连接的工人,也可以加载测试工作。当单击“停止”时,它会更改为“停止”,并且永远不会“停止”。
Observed an issue after clicking "stop" load test from web console of master node. "stop" status change to "stopping" status and hang there without reaching "stopped" state. When there is only 1 worker, it reaches properly to "stopped" state.. I had to restart locust master again to restart load test when it was hung on "stopping" state. Issue repeats when I have more than one worker.
I experienced this issue first when running master and workers on AWS fargate containers .Interestingly, there were no errors logged in master and worker containers after pressing stop button. With just single worker container, Stop status properly move to "stopped" on web console master. Having more than 1 worker cause this issue.
Later I could reproduce this issue on local machine without even docker.
When I run locust master and 2 workers from my local MacBook itself, I am experiencing this issue.
There are no errors thrown after clicking "stop". With 1 worker, it work fine and move to "stopped" status.
How to reproduce in local MacBook
- Start Locust master from one terminal with below command
locust -f my_locustfile.py --master
- Start 2 locust workers from another 2 terminals with below command
locust -f my_locustfile.py --worker.
(Ignored "--master-host" parameter here as it is local run. In AWS Fargate setup, we have that parameter)
After this master web console(http://0.0.0.0:8089/) shows 2 workers connected, also load test work fine. When click on "stop" it changes to "stopping" and never come to "stopped".
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这似乎是2020年Github上提到的蝗虫工具的错误,但直到现在
This appears to be a Bug with the locust tool that was mentioned on github back in 2020, but remains unfixed until now