0

I'm running a test from JMeter sending HTTPS requests to a load balancer that is then distributing the user load across multiple application servers. We have an instance where as the load grows we are seeing Non HTTP response code: org.apache.http.conn.HttpHostConnectException errors reported in JMeter. In this instance we are not seeing the requests making it to any of the application servers.

In order to isolate where the problem lies (Load Balancer or Load Generator) I was attempting to utilize Wireshark to validate request transmission, but it's unable to provide me with the information due to being HTTPS.

The issue is observed both in a single load generator configuration and JMeter Server configuration with 1 master and 2 load generators. All 3 are using JMeter 5.1.1 and are being hosted on a Windows Server VM.

0

Try to debug the issue with the below points

  • When you are getting Non HTTP response code: org.apache.http.conn.HttpHostConnectException error, whether the application can be accessed manually multiple times successfully.
  • Whether your server has enough free resources available in Server side to process the requests.
  • Whether your Load Generators are running out of memory. This may occur when requests are piled up in LG side.

Non HTTP response code: org.apache.http.conn.HttpHostConnectException

Error could occur in any of the below situations

  1. The connection may be refused by the server.

    Check the maximum number of allowed concurrent users in the server and increase it as needed.

  2. A firewall may be blocking the requests.

    Firewall may block the request since all the request are originating from same IP.

0
  1. As per HttpHostConnectException documentation

    A ConnectException that specifies the HttpHost that was being connected to.

  2. In its turn ConnectException documentation states that:

    Signals that an error occurred while attempting to connect a socket to a remote address and port. Typically, the connection was refused remotely (e.g., no process is listening on the remote address/port).

The error you're getting means that JMeter is not capable of establishing connection with the application you're testing. The reasons could be in:

  • Your application is overloaded. Check out its logs and in addition ensure that it has enough headroom to operate in terms of CPU, RAM, Disk, Network, etc. You can use JMeter PerfMon Plugin for this
  • Your application server or load balancer configuration doesn't match the load pattern. For example Apache web server by default allows 256 connections and if you will create 257 threads (virtual users) the last guy will get this ConnectException because Apache will not allow it.

  • You might be delivering more load that you think, when it comes to JMeter Distributed Testing load generators execute the same Test Plan so if you defined 1000 users in Thread Group and have 2 load generators - it means that you're producing 2000 virtual users

And last by not the least, it is possible to capture secure traffic with Wireshark, check out SSL/TLS Decryption - uncovering secrets article for configuration details.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.