itsky365
itsky365
// common-error.log ``` // 第一行至末尾全是这样的错误日志 2017-03-06 08:50:52,928 ERROR 5864 nodejs.ClusterClientNoResponseError: client no response in 13916ms, maybe the connection is close on other side. at Timeout.Leader._heartbeatTimer.setInterval [as _onTimeout] (/root/code/node_modules/cluster-client/lib/leader.js:59:23) at ontimeout...
@popomore @gxcsoccer 是不是cluster watcher 有问题?
@atian25 本地开发环境在 ubuntu16.10 下也同样出现上面的 ClusterClientNoResponseError 错误,有时导致nodejs响应比较慢。
// index.js ``` require('egg').startCluster({ workers: 8, // 多加的 baseDir: __dirname, port: process.env.PORT || 7001, // default to 7001 }); ``` // app/controller 也是日常的http处理逻辑 删除了node_modules目录,npm install 后运行再看看日志。 除非用了 ccap 生成的验证码 有冲突?
$ ps aux | grep node 结果如下,启动了2个node项目,一个work采用eggjs开发,一个code采用vue2 webpack开发 ``` $ ps aux | grep node root 2900 0.1 0.0 16332 2684 ? Ss 08:58 0:03 /sbin/mount.ntfs /dev/sda3 /media/zhuxh/12A62C8FA62C74FF -o rw,nodev,nosuid,uid=1000,gid=1000,uhelper=udisks2...
@gxcsoccer alpha 上刚刚部署了 node_modules 下,观看一天 common-error.log 才知道结果呢
``` 2017-03-07 18:30:43,217 ERROR 20965 nodejs.ClusterClientNoResponseError: client no response in 10158ms, maybe the connection is close on other side. at Timeout.Leader._heartbeatTimer.setInterval [as _onTimeout] (/root/np-node/node_modules/cluster-client/lib/leader.js:59:23) at ontimeout (timers.js:365:14) at tryOnTimeout (timers.js:237:5)...
@atian25 ``` [root@host-192-168-1-1 code]# cat common-error.log 2017-03-14 13:28:13,655 ERROR 28134 nodejs.ClusterClientNoResponseError: client no response in 31752ms exceeding maxIdleTime 30000ms, maybe the connection is close on other side. at Timeout.Leader._heartbeatTimer.setInterval [as...
@atian25 看了下 `cluster-client/lib/leader.js` 代码,写了一个心跳包的定时器。egg.js 必须要用 cluster-client吗?
@gxcsoccer @atian25 升级到 [email protected] 还是报 ClusterClientNoResponseError 错误,能解决吗?