V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
bigcoon
V2EX  ›  Node.js

有人用过 pm2 么,pm2 重启进程后,浏览器访问一直是请求等待中。。

  •  
  •   bigcoon · 2014-09-03 17:31:10 +08:00 · 4089 次点击
    这是一个创建于 3494 天前的主题,其中的信息可能已经有所发展或是发生改变。
    我故意写了个错误,第一次请求有效,日志里面错误也显示出来了,pm2 list看到进程也重新启动了,,但是用浏览器请求的时候一直在请求加载中,

    有用过pm2的指点一下哈
    6 条回复    2015-12-13 00:10:25 +08:00
    bigcoon
        1
    bigcoon  
    OP
       2014-09-03 18:46:01 +08:00
    擦,没人用过么,,本地是好的啊,就是线上不行,线上是CentOS 6.5
    bigcoon
        2
    bigcoon  
    OP
       2014-09-03 18:47:02 +08:00
    google baidu 了好几遍没有和我一样的情况。。
    Sokos
        3
    Sokos  
       2014-09-03 22:52:56 +08:00
    貌似最新PM2有这个问题,昨晚有个新部署节点(CentOS 6.5,64位)用了最新版本PM2。pm2 restart id 以后就hang住了,pm2 kill以后再pm2 start才好。
    bigcoon
        4
    bigcoon  
    OP
       2014-09-04 00:11:00 +08:00
    @Sokos 你问题解决了么?之前用的什么版本
    bigcoon
        5
    bigcoon  
    OP
       2014-09-04 00:14:16 +08:00
    @Sokos 我降到0.9.5好了。。擦,新玩意问题还是比较多
    cychai
        6
    cychai  
       2015-12-13 00:10:25 +08:00
    可能原因有两个:同一服务器起多个 pm2 进程; pm2 exec_mode 使用的是 cluster 模式,换成 fork
    可参见 http://blog.csdn.net/spring21st/article/details/50279437 这篇文章介绍
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   1544 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 26ms · UTC 17:01 · PVG 01:01 · LAX 10:01 · JFK 13:01
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.