Thursday, May 25, 2017

Re: CPU usage by workers

For those who have same CPU usage issue — my mistake was in isage RedisLocalChannelLayer in combo with delay server. 

Looks like many delayed messages just hangs on nodes. I've thought it should be executed on same node, but seems partially it was consumed, but partially hangs.
Then i've tried to run delay worker on single node and hope it'll consume delayed messages from all other nodes, but it's not work too.
Then i've switched this node from RedisLocalChannelLayer to RedisChannelLayer and seems like all nodes start to ignore this settings and consume all existed messages. Also CPU usage lowered to the 0-1%

So i've just switch all nodes to RedisChannelLayer.

On Monday, May 15, 2017 at 8:37:59 PM UTC+6, qnub wrote:
Thanks for suggestions but i have found nothing suspicious.

But i've installed pyinotify and switch to running workers in separate processes manually instead of using --threads option.
Not sure which of this actions helps more but now CPU usage floating around 15-25%

On Wednesday, May 10, 2017 at 5:58:38 PM UTC+6, Melvyn Sopacua wrote:

On Tuesday 09 May 2017 23:21:23 qnub wrote:

 

> Also it's may be my fault somewhere (and i pretty sure it is). But i

> not sure where to start my investigation.

 

I would start with strace - a common cause for this is expecting a resource that does not exist and keep trying. A filename or network address / port number can be that candle in the dark.

 

--

Melvyn Sopacua

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/4b845943-ec1d-4749-bb9b-5c5fe6a3bc10%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment