How does Meteor mup use forever?

孤街浪徒 提交于 2019-12-12 18:23:50

问题


I can read in the Meteor mup documentation that it uses forever to restart a process if it crashes:

https://github.com/arunoda/meteor-up

At the command line if I issue a "forever list" it reports

info:    No forever processes running

I have a Meteor app that keeps hanging and was wondering if I was using mup correctly, or if Forever would help.

Any advice would be appreciated. Please let me know if there is more information that I can provide.

  • Also someone with a higher reputation please tag this question with "mup" if that's possible.

回答1:


Forever should list the process if it's running.

Check logs of that server with: tail -f /var/log/upstart/meteor.log




回答2:


I was able to see the forever processes by adding the -H flag to sudo. sudo by itself was not revealing the processes.

ubuntu@ip-123-45-67-890:~$ sudo -H forever list
info:    Forever processes running
data:        uid  command  script      forever pid   logfile                 uptime         
data:    [0] Jaj_ userdown app/main.js 13041   13047 /root/.forever/Jaj_.log 0:16:56:27.894 

Looks like forever stores process information in the user's home directory, and somewhere in the mup process it was elevated to root and used that home directory. -H evidently made it look there.



来源:https://stackoverflow.com/questions/26821631/how-does-meteor-mup-use-forever

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!