[rabbitmq-discuss] RabbitMQ / Erlang not running on all cores?

Matt Pietrek mpietrek at skytap.com
Tue Oct 22 23:38:56 BST 2013


Thanks Michael.

The line:

"Erlang R15B01 (erts-5.9.1) [source] [64-bit] [smp:4:4] [async-threads:0]
[kernel-poll:false]"

is from running "erl" on the same VM as the broker.

Regarding the suggestion of "RABBITMQ_ALLOW_INPUT=true", this is a bit
tricky for me to run. For starters, this is a Rabbit instance running in a
production environment so I can't easily restart it. And even if I could,
the way we start RabbitMQ is a bit quirky (long story).

Is there some way to get the aysnc-threads value from a "rabbitmqctl
eval..." or from the logs? I do have ready access to those.

A few of the messages are persistent, but the vast majority of them are
non-persistent. Our disk I/O on the box looks relatively low. Many
intervals of 0 reads/writes with occasional blips up, but noting
particularly heavy.

Also, we are running this in a cluster with another box, with all queues in
HA mode. I imagine that would have some overall CPU impact, but don't see
why it would concentrate everything on one core.

Thanks again,

Matt



On Tue, Oct 22, 2013 at 2:46 PM, Michael Klishin <mklishin at gopivotal.com>wrote:

> On 23 Oct 2013, at 01:31, Matt Pietrek <mpietrek at skytap.com> wrote:
>
> > Thanks Zhibo. We actually have hundreds of queues. Two of them are
> processing several hundred messages/second. The remaining queues are
> processing 1 or 2 messages second.
>
> Then you should see at least two cores being moderately used.
>
> As you have correctly identified,
> Erlang VM detects 4 cores available to it. What is odd is that you have
> async-threads:0,
> which means disk I/O will block Erlang VM schedulers.
>
> Does the
>
> Erlang R15B01 (erts-5.9.1) [source] [64-bit] [smp:4:4] [async-threads:0]
> [kernel-poll:false]
>
> line come from RabbitMQ or just `erl` executed on the same machine?
>
> If you run rabbitmq with RABBITMQ_ALLOW_INPUT=true in the foreground and
> hit Enter,
> you should see how many async-threads it has configured.
> For me it's 30 vs 10 for a new Erlang shell.
>
> I'd also recommend using vmstat and similar tools to see how many threads
> wait on disk I/O.
> By the way, do you publish messages as persistent?
>
> MK
> _______________________________________________
> rabbitmq-discuss mailing list
> rabbitmq-discuss at lists.rabbitmq.com
> https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20131022/0dc3c10d/attachment.htm>


More information about the rabbitmq-discuss mailing list