Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1341208

Re: [PATCH v2] mm: scale kswapd watermarks in proportion to memory

From David Rientjes <rientjes@google.com>
Newsgroups linux.kernel
Subject Re: [PATCH v2] mm: scale kswapd watermarks in proportion to memory
Date 2016-02-24 01:40 +0100
Message-ID <r5vEK-4WP-5@gated-at.bofh.it> (permalink)
References <r58f8-55M-13@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Mon, 22 Feb 2016, Johannes Weiner wrote:

> In machines with 140G of memory and enterprise flash storage, we have
> seen read and write bursts routinely exceed the kswapd watermarks and
> cause thundering herds in direct reclaim. Unfortunately, the only way
> to tune kswapd aggressiveness is through adjusting min_free_kbytes -
> the system's emergency reserves - which is entirely unrelated to the
> system's latency requirements. In order to get kswapd to maintain a
> 250M buffer of free memory, the emergency reserves need to be set to
> 1G. That is a lot of memory wasted for no good reason.
> 
> On the other hand, it's reasonable to assume that allocation bursts
> and overall allocation concurrency scale with memory capacity, so it
> makes sense to make kswapd aggressiveness a function of that as well.
> 
> Change the kswapd watermark scale factor from the currently fixed 25%
> of the tunable emergency reserve to a tunable 0.001% of memory.
> 
> Beyond 1G of memory, this will produce bigger watermark steps than the
> current formula in default settings. Ensure that the new formula never
> chooses steps smaller than that, i.e. 25% of the emergency reserve.
> 
> On a 140G machine, this raises the default watermark steps - the
> distance between min and low, and low and high - from 16M to 143M.
> 
> Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>
> Acked-by: Mel Gorman <mgorman@suse.de>

Acked-by: David Rientjes <rientjes@google.com>

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v2] mm: scale kswapd watermarks in proportion to memory Johannes Weiner <hannes@cmpxchg.org> - 2016-02-23 00:40 +0100
  Re: [PATCH v2] mm: scale kswapd watermarks in proportion to memory Rik van Riel <riel@redhat.com> - 2016-02-23 02:40 +0100
    Re: [PATCH v2] mm: scale kswapd watermarks in proportion to memory Johannes Weiner <hannes@cmpxchg.org> - 2016-02-23 03:00 +0100
  Re: [PATCH v2] mm: scale kswapd watermarks in proportion to memory David Rientjes <rientjes@google.com> - 2016-02-23 03:30 +0100
    Re: [PATCH v2] mm: scale kswapd watermarks in proportion to memory Johannes Weiner <hannes@cmpxchg.org> - 2016-02-24 01:40 +0100
  Re: [PATCH v2] mm: scale kswapd watermarks in proportion to memory David Rientjes <rientjes@google.com> - 2016-02-24 01:40 +0100
  Re: [PATCH v2] mm: scale kswapd watermarks in proportion to memory Joonsoo Kim <iamjoonsoo.kim@lge.com> - 2016-02-25 01:40 +0100
    Re: [PATCH v2] mm: scale kswapd watermarks in proportion to memory Johannes Weiner <hannes@cmpxchg.org> - 2016-02-25 21:10 +0100

csiph-web