I'm using yii2-elasticsearch library that handles all request to elasticsearch with curl. The problem is that after 30000-40000 requests (aprox. speed is 18000rpm) I beging to receive curl error 7 (CURLE_COULDNT_CONNECT) on some of requests. I set all elasticsearch log levels to DEBUG and TRACE but it doesn't report any problems, so I think that this issue is related to curl itself and may be connected with some of OS settings (Ubuntu 14.04).
What can cause such kind of behavior?