Advanced, production process manager for Node.js
一、安装
二、启动一个项目
进入目标文件夹,

三、尽管去启动你的项目

四、监测所有的进程

五、列出所有进程

六、查看一个具体的进程详细情况
通过id或者name来查看某一具体进程:

七、停止进程
1
| pm2 stop <id|name|all|json|stdin>
|

八、重启进程
1
| pm2 restart <id|name|all|json|stdin>
|

九、删除进程
1
| pm2 delete <name|id|script|all|json|stdin>
|

十、查看日志

十一、自动重启应用watch

这里需要注意:pm2 stop 2 将不能停止watch,必须pm2 stop –watch 2
十二、相关资源:
1.官网
http://pm2.keymetrics.io/
2.github地址
https://github.com/Unitech/PM2
3.nodejs监视系统
https://app.keymetrics.io/#/register
4.快速开始
https://github.com/Unitech/PM2/blob/master/ADVANCED_README.md#quick-start-1