Answer the question
In order to leave comments, you need to log in
What are the causes of errors on Redis socket (Yii2)?
Tell me what could be the problem with Redis and Yii2. As far as I understand, at some points Redis does not have time to process requests and connections begin to grow sharply. I am getting these errors:
[error][yii\redis\SocketException] yii\redis\SocketException: Failed to read from socket.
Redis command was: GET 4409ee710349bf94ce421efc4bd946a2 in /var/www/prj/vendor/yiisoft/yii2-redis/src/Connection.php:804
[error][application] Failed to write to socket. 0 of 37 bytes written.
Redis command was: *2
$3
GET
$17
[error][yii\db\Exception] yii\db\Exception: Failed to open DB connection. in
/var/www/prj/vendor/yiisoft/yii2-redis/src/Connection.php:643
Answer the question
In order to leave comments, you need to log in
Try setting a connection timeout and the number of connection retries.
Related PR
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question