phpsocket 配置了SSL 低負(fù)載正常 連接數(shù)超多幾百就報(bào)錯(cuò)
很奇怪不知道問題出在哪里
// 傳入ssl選項(xiàng),包含證書的路徑
$context = array(
'ssl' => array(
'local_cert' => 'zhengshu.pem',
'local_pk' => 'zhengshu.key',
'verify_peer' => false,
)
);
handshake error: stream_socket_enable_crypto(): Unable to set local cert chain file `zhengshu.pem'; Check that your cafile/capath settings include details of your certificate and its issuer
此時(shí)前端會報(bào)525錯(cuò)誤 然后從ws連接變成了http輪詢
這是運(yùn)行的狀態(tài)圖 現(xiàn)在沒啥連接數(shù),但是只要高了就會報(bào)錯(cuò)
這是系統(tǒng)內(nèi)核已優(yōu)化 event也安裝了
經(jīng)過排查 好像是這個(gè)代碼導(dǎo)致的內(nèi)存泄漏 有大神幫我看看要如何處理
$msg = base64_encode(gzencode($send_msg,5));