JMeter永不失败 [英] JMeter never fails

查看:247
本文介绍了JMeter永不失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用JMeter对服务器进行压力测试.我遵循了手册并成功创建了测试(测试正在运行oke并且响应正确).

Im trying to stresstest a server with JMeter. I followed the manual and successfully created the tests (Test are running oke and response is correct).

但是,即使我不断增加线程数量,它也永远不会失败,但是我一直在读,一定有局限性吗?那我在做什么错了?

However even if i keep increasing the number of threads it never fails, but i keep reading that there must be limitations? So what am i doing wrong?

我未运行JMeter时,我的CPU的运行速度为+/- 5%.运行3000个线程,我发现线程数增加了3000,CPU使用率达到了+/- 15%.同样,JMeter也从不抱怨出问题了.

My CPU is running on +/-5% when im not running JMeter. Running 3000 threads i see the number of threads increase by 3000 and CPU usage goes to +/-15%. Also JMeter never complains something went wrong.

我的JMeter配置为: 线程数:3000 加速期:30 LoopCount:永远(让它运行一个小时以上,但仍然没有出现任何问题)

My JMeter configuration is: Number of threads: 3000 Ramp-Up Period: 30 LoopCount: Forever (Let it run for over an hour and still nothing goes wrong)

现在的瓶颈是我的互联网连接,根本无法处理此负载并以2.1Mbps的速度最大传输.这是引起问题的原因吗?它使我的等待时间从每线程10ms增加到每线程5000ms以上,但是线程仍在运行.

The bottleneck now is my internet connection wich simply cant handle this load and maxxes out at 2.1Mbps. Is this causing the problem? It is increasing my latency from 10ms per thread to over 5000ms per thread, but threads are still running..

推荐答案

假定您已经确认自己绝对不会找回任何错误(例如,使用结果表侦听器,或者使用结果图侦听器仅记录/显示错误) ),并且您的互联网连接已满负荷运行,是的,听起来您的互联网连接确实是瓶颈.听起来好像服务器根本没有压力.

Assuming you have confirmed that you definitely aren't getting back any errors (e.g. using a results table listener, or logging/displaying only errors using a results graph listener) and your internet connection is running at capacity then yes, it does sound like your internet connection is the bottleneck. It doesn't sound like your server is being stressed at all.

如果您可以轻松利用其他计算机(例如与要测试的服务器位于同一位置的服务器),则可以尝试使用JMeter远程(分布式)测试来规避Internet连接的限制.参见 http://jmeter.apache.org/usermanual/remote-test.html了解详情.

If you can easily make use of other machines (e.g. servers in the same location as the server you are testing), you could try using JMeter remote (distributed) testing to sidestep the limitations of your internet connection. See http://jmeter.apache.org/usermanual/remote-test.html for details.

或者,如果很简单(例如,如果您在云中使用VM,并且可以轻松地将其与软件一起旋转),则可以尝试使用性能最低的服务器,并对其进行压力测试以查看是否即使您连接了互联网,也可以让它挣扎(仅作为健全性检查).

Alternatively, if it's easy (e.g. if you're using VM's in a cloud and can easily spin one up with your software on), you could try using the least-powerful server you can instead and stress testing that to see if you can make it struggle even with your internet connection (just as a sanity check).

如果这没有帮助,则有关服务器的更多详细信息(硬件规格,Web服务器软件和线程池设置,语言)以及要测试的站点/页面(主要是静态或动态?大型请求/响应?)有用.我当然设法通过2Mbps的连接使用JMeter使功率较低的机器(例如EC2 m1.small)陷入困境,但这取决于您正在测试的站点.

If this doesn't help, more details on your server (hardware specifications, web server software and thread pool settings, language) and the site/pages you are testing (mostly static or dynamic? large requests/responses?) would be useful. I've certainly managed to make lower-powered machines (e.g. EC2 m1.small) struggle using JMeter over a 2Mbps connection, but it depends on the site you're testing.

这篇关于JMeter永不失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆