title: JMeter inconsistent CommunicationsException: Communications link failure
body: <pre><code>com.mysql.cj.jdbc.exceptions.CommunicationsException: Communications link failure
  
  The last packet successfully received from the server was 976,464 milliseconds ago. The last packet sent successfully to the server was 974,674 milliseconds ago.
  </code></pre>
  <p>This error occurs in JMeter when I ran the following test plan that would send 15 MB files to AWS RDS.</p>
  <pre><code>LoadTestPlan
    JDBC Connection Configuration: 
       Max Wait ms: 0 (indefinite wait)
       Max connections: 0 (no limit)
    ThreadGroup
        No. of threads: 200
        Ramp up seconds: 100
        Loop Count: Indefinite
        Scheduled to run for 3 hours
      JDBC Request
         LOAD DATA LOCAL INFILE statement
  </code></pre>
  <p>RDS Configuration</p>
  <pre><code>Engine 5.7.33
  Max connections: 200
  Innodb lock wait timeout: 6000
  Max allowed packet: 64 MB
  </code></pre>
  <p>There were many solutions for this Communication Links Failure but for me, some requests are successful and for some I get this error. Thus I am starting to think it is the network problem but I am using high speed Ethernet of 74 Mbps speed. Even if it is the network problem there must be some parameter that when adjusted should allow connections from even poor network to be successful.</p>
  <p>JMter version: 5.4</p>
  <p><a href="https://i.stack.imgur.com/Sun9C.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Sun9C.png" alt="enter image description here" /></a></p>