~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 16.04.5 LTS
Release: 16.04
Codename: xenial
$ pm2 list
>>>> In-memory PM2 is out-of-date, do:
>>>> $ pm2 update
In memory PM2 version: 2.4.6
Local PM2 version: 3.0.3
pm2 update
...在重启之前一直有效
npm remove pm2 -g
which pm2
npm install pm2@latest -g
which pm2
sudo reboot
有指针吗?
答案 0 :(得分:0)
我遇到了同样的问题,可以通过重新创建启动脚本来解决。请尝试以下步骤:
pm2 delete nameOfProcess
pm2 unstartup systemd
pm2 update
pm2 startup //copy paste the output
pm2 start nameOfProcess
pm2 save