[英]PM2 home directory on Windows
I have a logs
folder in C:\\Users\\username.pm2\\logs, but whenever I try to start pm2 I am getting this error in my Logs: 我在C:\\ Users \\ username.pm2 \\ logs中有一个
logs
文件夹,但是每当我尝试启动pm2时,我的日志中都会出现此错误:
PM2: 2015-11-20 13:23:32: Starting execution sequence in -fork mode- for app name:app id:0
PM2: 2015-11-20 13:23:32: Trace: [Error: can not create directories (logs/pids):ENOENT: no such file or directory, mkdir 'D:\Users\username\.pm2\logs']
So I think this is a config issue. 所以我认为这是一个配置问题。 How can I change the PM2 home directory to
C:\\Users\\username\\.pm2
instead of D:\\Users\\username\\.pm2
? 如何将PM2主目录更改为
C:\\Users\\username\\.pm2
而不是D:\\Users\\username\\.pm2
?
Apperantly this is an open issue on their github page, so I came up with two possible solutions: 显然,这是他们github页面上的一个未解决问题,因此我想出了两种可能的解决方案:
you can make those folders on your other drive: D:\\Users\\username\\.pm2
您可以在其他驱动器上创建这些文件夹:
D:\\Users\\username\\.pm2
or just reisntall pm2: 或只是reisntall pm2:
npm uninstall -g pm2
npm install -g pm2
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.