LearnBoost / cluster

Node.JS multi-core server manager with plugins support.

Home Page:http://learnboost.github.com/cluster

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Cluster workers are not getting fully used.

saikrishna15 opened this issue · comments

I'm running this code https://github.com/igrigorik/node-spdyproxy/blob/master/bin/spdyproxy on a 32 core linux system(virtual server), however

I added following code http://pastebin.com/MmuS5Ptg just commented proxy.listen code and added the above snippet of pastebin, when I ran the command below as said in this module documentation (https://www.npmjs.org/package/spdyproxy)

spdyproxy -k keys/mykey.pem -c keys/mycert.pem -p 44300 -v
which gave me 32 threads. I'm not sure if all these threads are running, when I do a top command I get this topcommand
Only few nodes are being used? Why is this. I'm using node version v0.10.26 and latest cluster.

Exact issue I have...One node process is used extensively to 100%, all other node processes used lightly under 5%, this is extremely unbalanced.

I am launching 100k connections with only two client simulation machine though (each machine launching about 50k test client connections) This means all 100k clients only have 2 unique IP. I am not sure how Node.js balances connections in relation to IP though.

PLEASE HELP!!!!
PLEASE HELP!!!!
PLEASE HELP!!!!
PLEASE HELP!!!!

BTW, my setup has nothing to do with the setup above...it is just a typical master worker cluster setup with websocket server. Like the example in here:

http://nodejs.org/api/cluster.html

How does Cluster load balance workers????????????
If I setup Haproxy load balancer with two node instances listening to two different ports, the node instances get extremely balanced, each using exact same amount of cpu and serve exact same amount of clients.

PLEASE HELP!!!!

Hey, We tried this, it got ,me little positive results like 4_num_of_Cpus in for loop or 6_num_of_cpus, but be careful with that, this experiment if more than 4 or 6 is tried, your server may use up all cpu and even wont allow you to login.

what is 4*num_of_Cpus? didn't understand

THE ISSUE IS NOT JUST 100% CPU usage. The real problem is when 1 cpu is loaded to 100%, it is using up lots of memory as well. My worker crashes and that probably relates to the V8 1.7GB process memory limit.............