It is hard to tell what exactly causes your problems. There are many things involved, which could go wrong. A few suggestions to look at:
If you suspect heap space limitations, have a look at the JVM statistics during the run. jstats, visualvm or jmc might help you detect those.
What I suspect is, that you ran out of other resources like tcp connections (on client, server or somewhere in between). That might lead to a synchronization of your simulated clients, which then might overload the target.
Try to connect to the server under test when those SocketExceptions occur. If you are not able to connect to the server too, than have a look at the server, is it overloaded?
Expected behavior
this is my heap config : "${HEAP:="-Xms5g -Xmx5g -XX:MaxMetaspaceSize=1024m"}" This memory and CPU look very normal this is part of runtime log
Actual behavior
I want to know why I behave strangely under high pressure and if it can be resolved
Steps to reproduce the problem
there are my plugins
JMeter Version
5.4.1
Java Version
java version "1.8.0_144" Java(TM) SE Runtime Environment (build 1.8.0_144-b01) Java HotSpot(TM) 64-Bit Server VM (build 25.144-b01, mixed mode)
OS Version
centos7