error: Forever cannot find process with id #636

Closed
bitliner opened this Issue Nov 12, 2014 · 11 comments

Projects

None yet

6 participants

@bitliner

My app is currently running, let's say its name is name.js.

If I run forever list, it shows name.js related entry.

But if I run forever stop name.js it throws

error:   Forever cannot find process with id: name.js

If I look at ps aux output, it shows one entry for the currently running name.js app, and one entry for the monitor process.

Versions:
node: 0.10.33
npm: 1.4.28
forever: 0.13.0

@Tjatse
Contributor
Tjatse commented Nov 12, 2014

MISTAKE This was fixed on v0.14.0, we are waiting for @indexzero to publish the new version, be patient, sorry.

@bitliner

Do you know approximately how much I should wait for it? Because to solve it I would directly install a previous version...

@Tjatse
Contributor
Tjatse commented Nov 12, 2014

If you have a directory like /User/bitliner/Node/app, and the entry is name.js, forever stop only works in following manners:
Start it like these:

$ cd /User/bitliner/Node/app
$ forever start name.js

or

$ cd /User/bitliner/Node
$ forever start app/name.js

or

$ cd ~/
$ forever start --sourceDir /User/bitliner/Node/app name.js

If you wanna stop it, try to pass a relative or absolute path, like:

$ cd /User/bitliner/Node/app
$ forever stop name.js

or

$ cd /User/bitliner/Node/app
$ forever stop ./name.js

or

$ cd /User/bitliner/Node
$ forever stop app/name.js

or

$ cd ~/
$ forever stop /User/bitliner/Node/app/name.js
@Tjatse
Contributor
Tjatse commented Nov 12, 2014

BTW, usage:

forever stop <PID | UID | INDEX | SCRIPT>

We recommend using pid, uid, index. e.g.:
if pid is 24789

forever stop 24789

and if index is [0]

forever stop 0

and if uid is uX0l

forever stop uX0l
@bitliner

@Tjatse I am doing exactly what you posted.

npm start is cd ./bin && forever start ./app.js

while

npm stop is cd bin && forever stop ./app.js

but it does not work :(

Even stoppping by pid does not work. By uid does.

And I am also noting it with forever 0.11.1

@bitliner

Now it is working, but as following
forever start ./app.js
forever stop app.js

While if I run forever stop ./app.js does not work.

@duxbuse
duxbuse commented Dec 12, 2014

I was having the same issues. The only way I could get it to work was with --uid.

@eric-tucker

Same issue here. It's been a month and a half. What is the hold up in getting the fix published to the NPM repository?

@indexzero
Member

Published.

@indexzero indexzero closed this Dec 30, 2014
@eric-tucker

Thanks!

@Dzenly
Dzenly commented Jul 14, 2015

Still facing similar problem.
After "exec forever start --sourceDir=$sourceDir -p $pidsDir $sourceName $arguments"
I have to use "forever stop $sourceDir/$sourceName".

@empierre empierre referenced this issue in empierre/MyDomoAtHome Mar 29, 2016
Closed

stopping forever process #80

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment