phpsocket.io icon indicating copy to clipboard operation
phpsocket.io copied to clipboard

fread(): SSL: Connection reset by peer in

Open den1a opened this issue 2 years ago • 2 comments

Hello. I get this error from the logo. Please tell me what to pay attention to.

PHP Warning: fread(): SSL: Connection reset by peer in /var/www/site/vendor/workerman/workerman/Connection/TcpConnection.php on line 582

Certificate files are readable

'ssl' => [
  'local_cert'  => '/etc/nginx/ssl/www.site.crt',
  'local_pk'    => '/etc/nginx/ssl/www.site.crt',
  'verify_peer' => false,
]

den1a avatar Jul 17 '23 08:07 den1a

It appears that the connection was forcibly terminated by the client, which is a predictable warning and usually does not require special handling In the workerman source code @ is used to suppress such warnings.

walkor avatar Jul 18 '23 00:07 walkor

I see @ in the source code, but I still get a lot of errors in my error log

error

error2

den1a avatar Jul 27 '23 11:07 den1a

@den1a it's not "a lot of errors", it's called stack trace showed where this error occur, so error only one here: "Connection reset by peer", it's just warning, so you can simply supress it as @walkor mentioned because it will recover automatically in case of disconnection.

acuna-public avatar Apr 10 '24 17:04 acuna-public