JMeter 远程测试 - 2 个奴隶

JMeter Remote testing - 2 slaves

我正在我的系统上执行 JMeter 负载测试。我们有 1 个带有 JMeter GUI 的客户端服务器和 2 个从属服务器。

例如 客户端:192.168.1.1 奴隶1:192.168.1.2 slave2: 192.168.1.3

我们正在测试需要登录、执行某些操作和注销的应用程序。 是否可以使用 2 个以上的从站测试此类应用程序?因为在当前会话中我无法在服务器上多次使用同一用户登录。我收到许可证错误:"User is connected from another machine"。 我知道,jmeter 将线程数乘以从属数,但如何处理这种情况?

谢谢

JMeter 在分布式模式下使用本地 CSV 文件。所以你只要在每个从机上放置不同的文件就可以了。

对于分布式测试,CSV 文件必须存储在服务器主机系统上 JMeter 服务器启动的正确相对目录中。

根据Apache JMeter documentation,

By default, the file is only opened once, and each thread will use a different line from the file. However, the order in which lines are passed to threads depends on the order in which they execute, which may vary between iterations.

If you want each thread to have its own set of values, then you will need to create a set of files, one for each thread. For example test1.csv, test2.csv, …, testn.csv. Use the filename test${__threadNum}.csv and set the "Sharing mode" to "Current thread".

所以只需将您的不同凭据放在不同的 CSV 文件中即可。

以下任一解决方案都可以解决您的问题。我用的是 Redis。超级酷。

Redis:

http://www.testautomationguru.com/jmeter-make-data-sharing-easy-in-distributed-mode-using-redis/

HTTP 简单 Table 服务器:

https://jmeter-plugins.org/wiki/HttpSimpleTableServer