kinisi / kinisi-agent-nodejs

Kinisi Agent written in NodeJS
MIT License
1 stars 0 forks source link

Node/NPM/Forever cannot find process with id: kinisi-agent.js #10

Open aeratek opened 9 years ago

aeratek commented 9 years ago

Subject describes the error message, when attempting to stop the kinisiagent service using "sudo service kinisiagent stop". Possibly a bug in the way that the node package "forever" is unable to handle stopping a service that does not have the same name as the executable, i.e. "kinisiagent" service versus "kinisi-agent.js" as the executable run by node. Screenshot attached of an attempt to manually stop the service using absolute path by typing "sudo forever /usr/local/kinisi-agent-nodejs/kinisi-agent.js stop". Found article on forever bug, which may be applicable: https://github.com/foreverjs/forever/issues/636 photo

Was able to stop the Kinisi Agent by performing the kill command on the PID.

transistorize commented 9 years ago

I've posted a fix to the kinisiagent service script. Please test on a different device and let me know. The start, stop, restart, and status commands were all modified to be a little more resilient.

https://github.com/kinisi/kinisi-agent-nodejs/commit/08a35edfe1c4b5d3687c71007d85425b5e058981