mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Nick Piggin <nickpiggin@yahoo.com.au>
To: Solofo.Ramangalahy@bull.net
Cc: linux-kernel@vger.kernel.org
Subject: Re: [RFC -mm 0/6] sysv ipc: scale msgmnb with the number of cpus
Date: Fri, 6 Jun 2008 18:23:22 +1000	[thread overview]
Message-ID: <200806061823.22639.nickpiggin@yahoo.com.au> (raw)
In-Reply-To: <20080606060955.317871352@bull.net>

On Friday 06 June 2008 16:09, Solofo.Ramangalahy@bull.net wrote:
> The size in bytes of a SysV IPC message queue, msgmnb, is too small
> for large machines, but we don't want to bloat small machines

What's your evidence for this? Can you provide before / after
performance numbers?

Also, when scaling things like this, it is probably more usual
to use a log scale rather than linear, so that's a thought.

>
> Several methods are used already to modify (mainly increase) msgmnb:
> . distribution specific patch
> . system wide sysctl.conf
> . application specific tuning via /proc/sys/kernel/msgmnb
>
> Integrating this series would:
> . reflect hardware and software evolutions and diversity,
> . reduce configuration/tuning for the applications.
>
> Here is the timeline of the evolution of MSG* #defines:
> Year             1994         1999         1999          2008
> Version           1.0       2.3.27       2.3.30        2.6.24
> #define MSGMNI    128          128           16            16
> #define MSGMAX   4056         8192         8192          8192
> #define MSGMNB  16384        16384        16384         16384
>
> This patch series scales msgmnb, with respect to the number of
> cpus/cores for larger machines. For uniprocessor machines the value
> does not increase.
>
> This series is similar to (and depends on) the series which scales
> msgmni, the number of IPC message queue identifiers, to the amount of
> low memory.
> While Nadia's previous series scaled msgmni along the memory axis,
> hence the message pool (msgmni x msgmnb), this series uses a second
> axis: the number of online CPUs.
> As well as covering the (cpu,memory) space of machines size, this
> reflects the parallelism allowed by lockless send/receive for
> in-flight messages in queues (msgmnb / msgmax messages).
>
> The initial scaling is done at initialization of the ipc namespace.
> Furthermore, the value becomes dynamic with respect to cpu hotplug.
>
> The msgmni and msgmnb values become dependent, as the value of msgmni
> is computed with respect to the value of msgmnb.
>
> The series is as follows:
> . patch 1 introduces the scaling function
> . patch 2 deals with cpu hotplug
> . patch 3 allows user space to disable the scaling mechanism
> . patch 4 allows user space to reenable the scaling mechanism
> . patch 5 finer grain disabling/reenabling scaling mechanism
>           (disconnect msgmnb and msgmni)
> . patch 6 adds documentation
>
> ---
>
> The series applies to 2.6.26-rc2-mm1 + patch suppressing KERN_INFO
> messages as discussed at:
> http://article.gmane.org/gmane.linux.kernel/686229
> "[PATCH 1/1] Only output msgmni value at boot time"
> (in mmotm: ipc-only-output-msgmni-value-at-boot-time.patch)
>
> The plan would be to have this ready for the 2.6.27 merge window if
> there are no objections.
>
>  Documentation/sysctl/kernel.txt |   27 ++++++++++++++++++++++
>  include/linux/ipc_namespace.h   |    4 ++-
>  include/linux/msg.h             |    5 ++++
>  ipc/ipc_sysctl.c                |   48
> ++++++++++++++++++++++++++++++---------- ipc/ipcns_notifier.c            | 
>  23 +++++++------------
>  ipc/msg.c                       |   25 +++++++++++++++++---
>  ipc/util.c                      |   28 +++++++++++++++++++++++
>  ipc/util.h                      |    1
>  8 files changed, 131 insertions(+), 30 deletions(-)

  parent reply	other threads:[~2008-06-06  8:23 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-06-06  6:09 Solofo.Ramangalahy
2008-06-06  6:09 ` [RFC -mm 1/6] sysv ipc: scale msgmnb to " Solofo.Ramangalahy
2008-06-06  6:09 ` [RFC -mm 2/6] sysv ipc: recompute msgmnb (and msgmni) on cpu hotplug addition and removal Solofo.Ramangalahy
2008-06-06  6:09 ` [RFC -mm 3/6] sysv ipc: do not recompute msgmni anymore if explicitely set by user Solofo.Ramangalahy
2008-06-06  6:09 ` [RFC -mm 4/6] sysv ipc: re-enable msgmnb automatic recomputing if set to negative Solofo.Ramangalahy
2008-06-06  6:10 ` [RFC -mm 5/6] sysv ipc: deconnect msgmnb and msgmni deactivation and reactivation Solofo.Ramangalahy
2008-06-10  7:05   ` Nadia Derbey
2008-06-06  6:10 ` [RFC -mm 6/6] sysv ipc: documentation for msgmnb scaling wrt. cpus Solofo.Ramangalahy
2008-06-06  8:23 ` Nick Piggin [this message]
2008-06-06 10:20   ` [RFC -mm 0/6] sysv ipc: scale msgmnb with the number of cpus Solofo.Ramangalahy
2008-06-10  6:56 ` Nadia Derbey
     [not found] <20080605145712.116223941@bull.net>
2008-06-07 14:38 ` Manfred Spraul
2008-06-08  7:19   ` Solofo.Ramangalahy
2008-06-23 13:15   ` Solofo.Ramangalahy
2008-06-24 18:00     ` Manfred Spraul
2008-06-25  6:18       ` Solofo.Ramangalahy
2008-06-25 10:12       ` Nadia Derbey

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200806061823.22639.nickpiggin@yahoo.com.au \
    --to=nickpiggin@yahoo.com.au \
    --cc=Solofo.Ramangalahy@bull.net \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®