【发布时间】:2019-11-13 08:20:15
【问题描述】:
我在 Windows server 2012 上安装了pm2
npm install pm2 -g
我关闭了我的 PowerShell 并再次打开它。
当我尝试运行 pm2 时失败并出现此错误
> pm2 list
pm2 : The term 'pm2' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ pm2 list
+ ~~~
+ CategoryInfo : ObjectNotFound: (pm2:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
我注意到 PM2_HOME 未设置,因此我将其设置为我的主目录中的 .pm2,但这没有帮助
任何指针?
有趣的是,我让它在同一台机器上的另一个帐户上工作。
【问题讨论】: