New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Status for node 0.10.x running pm2 on cluster mode #957

Closed
geekyme opened this Issue Jan 23, 2015 · 14 comments

Comments

6 participants
@geekyme

geekyme commented Jan 23, 2015

Hi guys,

What's the status for the cluster mode option on latest pm2 + node 0.10.x?
When I tried the command it appears that only 1 process is being started.

user@server:~$ pm2 start app -i max
[PM2] [WARN] Deprecated, we recommend using 0 instead of max to indicate maximum of instances.
[PM2] [WARN] You should not use the cluster_mode (-i) in production, it's still a beta feature. A front HTTP load balancer or interaction with NGINX will be developped in the future.

image

@Tjatse

This comment has been minimized.

Show comment
Hide comment
@Tjatse

Tjatse Jan 23, 2015

Collaborator

node v0.10.x has too many bugs with cluster module, try to use node v0.11.x instead of it if you still wanna use cluster mode.

Collaborator

Tjatse commented Jan 23, 2015

node v0.10.x has too many bugs with cluster module, try to use node v0.11.x instead of it if you still wanna use cluster mode.

@jshkurti

This comment has been minimized.

Show comment
Hide comment
@jshkurti

jshkurti Jan 26, 2015

Contributor

Node.js cluster module is still unstable (https://nodejs.org/docs/latest/api/cluster.html)
But as the warning says, -i max is deprecated, try -i 0 instead :)

Contributor

jshkurti commented Jan 26, 2015

Node.js cluster module is still unstable (https://nodejs.org/docs/latest/api/cluster.html)
But as the warning says, -i max is deprecated, try -i 0 instead :)

@geekyme

This comment has been minimized.

Show comment
Hide comment
@geekyme

geekyme Jan 26, 2015

I see. Are there other ways I can try to make node make use of my quad core CPUs ?

Sent from my iPhone

On 26 Jan 2015, at 9:55 pm, Joni Shkurti notifications@github.com wrote:

Node.js cluster module is still unstable (https://nodejs.org/docs/latest/api/cluster.html)
But as the warning says, -i max is deprecated, try -i 0 instead :)


Reply to this email directly or view it on GitHub.

geekyme commented Jan 26, 2015

I see. Are there other ways I can try to make node make use of my quad core CPUs ?

Sent from my iPhone

On 26 Jan 2015, at 9:55 pm, Joni Shkurti notifications@github.com wrote:

Node.js cluster module is still unstable (https://nodejs.org/docs/latest/api/cluster.html)
But as the warning says, -i max is deprecated, try -i 0 instead :)


Reply to this email directly or view it on GitHub.

@jshkurti

This comment has been minimized.

Show comment
Hide comment
@jshkurti

jshkurti Jan 26, 2015

Contributor

-i 0 works fine :)
The cluster module status is 'experimental' but it works nevertheless.
It is just not recommended using it in production for the moment but it still works fine most of the time.

Contributor

jshkurti commented Jan 26, 2015

-i 0 works fine :)
The cluster module status is 'experimental' but it works nevertheless.
It is just not recommended using it in production for the moment but it still works fine most of the time.

@Unitech

This comment has been minimized.

Show comment
Hide comment
@Unitech

Unitech Jan 27, 2015

Owner

I definetely not recommend to use it with Node 0.10.x.
With Node 0.11.14+ & iojs it's much better

Owner

Unitech commented Jan 27, 2015

I definetely not recommend to use it with Node 0.10.x.
With Node 0.11.14+ & iojs it's much better

@Unitech Unitech closed this Jan 27, 2015

@geekyme

This comment has been minimized.

Show comment
Hide comment
@geekyme

geekyme Jan 27, 2015

I just tried it with node v0.11.15. It is not working for me

PM2: 2015-01-27 10:51:07: Error: spawn ENOENT
PM2: at errnoException (child_process.js:1011:11)
PM2: at Process.ChildProcess._handle.onexit (child_process.js:802:34)
PM2: 2015-01-27 10:51:07: App name:app id:8 exited
PM2: 2015-01-27 10:51:07: Starting execution sequence in -cluster mode- for app name:app id:8
PM2: 2015-01-27 10:51:07: Error: spawn ENOENT
PM2: at errnoException (child_process.js:1011:11)
PM2: at Process.ChildProcess._handle.onexit (child_process.js:802:34)
PM2: 2015-01-27 10:51:07: App name:app id:8 exited
PM2: 2015-01-27 10:51:07: Starting execution sequence in -cluster mode- for app name:app id:8
PM2: 2015-01-27 10:51:07: Error: spawn ENOENT
PM2: at errnoException (child_process.js:1011:11)
PM2: at Process.ChildProcess._handle.onexit (child_process.js:802:34)
PM2: 2015-01-27 10:51:07: App name:app id:8 exited
PM2: 2015-01-27 10:51:07: Script /home/carousell/aizen/app.js had too many unstable restarts (15). Stopped. "errored"

On 27 Jan 2015, at 10:40 pm, Alexandre Strzelewicz notifications@github.com wrote:

Closed #957 #957.


Reply to this email directly or view it on GitHub #957 (comment).

geekyme commented Jan 27, 2015

I just tried it with node v0.11.15. It is not working for me

PM2: 2015-01-27 10:51:07: Error: spawn ENOENT
PM2: at errnoException (child_process.js:1011:11)
PM2: at Process.ChildProcess._handle.onexit (child_process.js:802:34)
PM2: 2015-01-27 10:51:07: App name:app id:8 exited
PM2: 2015-01-27 10:51:07: Starting execution sequence in -cluster mode- for app name:app id:8
PM2: 2015-01-27 10:51:07: Error: spawn ENOENT
PM2: at errnoException (child_process.js:1011:11)
PM2: at Process.ChildProcess._handle.onexit (child_process.js:802:34)
PM2: 2015-01-27 10:51:07: App name:app id:8 exited
PM2: 2015-01-27 10:51:07: Starting execution sequence in -cluster mode- for app name:app id:8
PM2: 2015-01-27 10:51:07: Error: spawn ENOENT
PM2: at errnoException (child_process.js:1011:11)
PM2: at Process.ChildProcess._handle.onexit (child_process.js:802:34)
PM2: 2015-01-27 10:51:07: App name:app id:8 exited
PM2: 2015-01-27 10:51:07: Script /home/carousell/aizen/app.js had too many unstable restarts (15). Stopped. "errored"

On 27 Jan 2015, at 10:40 pm, Alexandre Strzelewicz notifications@github.com wrote:

Closed #957 #957.


Reply to this email directly or view it on GitHub #957 (comment).

@jshkurti

This comment has been minimized.

Show comment
Hide comment
@jshkurti

jshkurti Jan 27, 2015

Contributor

We had some incompatibility issues with Node.js v0.11.15.
It is fixed now :)
npm install git://github.com/Unitech/pm2#master -g and try again.

Contributor

jshkurti commented Jan 27, 2015

We had some incompatibility issues with Node.js v0.11.15.
It is fixed now :)
npm install git://github.com/Unitech/pm2#master -g and try again.

@geekyme

This comment has been minimized.

Show comment
Hide comment
@geekyme

geekyme Jan 27, 2015

ok all’s good now. pm2 is at 0.12.3 and all I needed to do was to pm2 kill, then restart all my apps.

Works like a charm. Thanks so much.

On 27 Jan 2015, at 11:54 pm, Joni Shkurti notifications@github.com wrote:

We had some incompatibility issues with Node.js v0.11.15.
It is fixed now :)
npm install git://github.com/Unitech/pm2#master -g and try again.


Reply to this email directly or view it on GitHub #957 (comment).

geekyme commented Jan 27, 2015

ok all’s good now. pm2 is at 0.12.3 and all I needed to do was to pm2 kill, then restart all my apps.

Works like a charm. Thanks so much.

On 27 Jan 2015, at 11:54 pm, Joni Shkurti notifications@github.com wrote:

We had some incompatibility issues with Node.js v0.11.15.
It is fixed now :)
npm install git://github.com/Unitech/pm2#master -g and try again.


Reply to this email directly or view it on GitHub #957 (comment).

@jshkurti

This comment has been minimized.

Show comment
Hide comment
@jshkurti

jshkurti Jan 27, 2015

Contributor

You're welcome, thanks for the feedback.
We'll publish pm2 0.12.4 soon ;)

Contributor

jshkurti commented Jan 27, 2015

You're welcome, thanks for the feedback.
We'll publish pm2 0.12.4 soon ;)

@pravin-mindstix

This comment has been minimized.

Show comment
Hide comment
@pravin-mindstix

pravin-mindstix Mar 11, 2015

Hi,

I used pm2 start app -i max or pm2 start app -i 0 command still it showing one process running as fork mode.

my node version is
node -v
v0.12.0

Thanks.
screen shot 2015-03-11 at 12 28 27 pm

pravin-mindstix commented Mar 11, 2015

Hi,

I used pm2 start app -i max or pm2 start app -i 0 command still it showing one process running as fork mode.

my node version is
node -v
v0.12.0

Thanks.
screen shot 2015-03-11 at 12 28 27 pm

@jorge-d

This comment has been minimized.

Show comment
Hide comment
@jorge-d

jorge-d Mar 11, 2015

Contributor

@pravin-mindstix Which version of pm2 ?

Contributor

jorge-d commented Mar 11, 2015

@pravin-mindstix Which version of pm2 ?

@pravin-mindstix

This comment has been minimized.

Show comment
Hide comment
@pravin-mindstix

pravin-mindstix Mar 11, 2015

i am using
pm2 -v
0.12.7

pravin-mindstix commented Mar 11, 2015

i am using
pm2 -v
0.12.7

@jorge-d

This comment has been minimized.

Show comment
Hide comment
@jorge-d

jorge-d Mar 11, 2015

Contributor

I just tested with node v0.12.0 and pm2 0.12.7 and everything seems to be working fine...
Could you do a simple test ? run pm2 kill; pm2 start app.js -i 0 and tell me whether it starts in cluster of fork mode ?

Contributor

jorge-d commented Mar 11, 2015

I just tested with node v0.12.0 and pm2 0.12.7 and everything seems to be working fine...
Could you do a simple test ? run pm2 kill; pm2 start app.js -i 0 and tell me whether it starts in cluster of fork mode ?

@pravin-mindstix

This comment has been minimized.

Show comment
Hide comment
@pravin-mindstix

pravin-mindstix Mar 11, 2015

screen shot 2015-03-11 at 4 15 09 pm
Ohh.. after pm2 kill; its work for me :)

i hit pm2 start app.js -i 4 and its showing 4 cluster mode. :)

Thank you so much Jorge-d

pravin-mindstix commented Mar 11, 2015

screen shot 2015-03-11 at 4 15 09 pm
Ohh.. after pm2 kill; its work for me :)

i hit pm2 start app.js -i 4 and its showing 4 cluster mode. :)

Thank you so much Jorge-d

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