From: Tomas Vondra <tomas.vondra@2ndquadrant.com>
To: pgsql-performance@postgresql.org
Subject: Re: MusicBrainz postgres performance issues
Date: Sun, 15 Mar 2015 14:28:59 +0100
Message-ID: <5505891B.6060800@2ndquadrant.com> (raw)
In-Reply-To: <9E71CCBE-4CDF-482E-878D-6C16027B6283@musicbrainz.org>
References: <B008F2EE-45D7-4535-9163-56A8CDCA553C@musicbrainz.org>
<CAB6McgXxZdD6yuYRLg4tgDdhqzXKLs63aV+S_nOfZ9arSXUAhA@mail.gmail.com>
<9E71CCBE-4CDF-482E-878D-6C16027B6283@musicbrainz.org>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-performance>
On 15.3.2015 13:07, Robert Kaye wrote:
>
>> If the load problem really is being caused by swapping when things
>> really shouldn't be swapping, it could be a matter of adjusting your
>> swappiness - what does cat /proc/sys/vm/swappiness show on your server?
>
> 0
>
> We adjusted that too, but no effect.
>
> (I’ve updated the blog post with these two comments)
IMHO setting swappiness to 0 is way too aggressive. Just set it to
something like 10 - 20, that works better in my experience.
>> There are other linux memory management things that can cause
>> postgres and the server running it to throw fits like THP and zone
>> reclaim. I don't have enough info about your system to say they are
>> the cause either, but check out the many postings here and other
>> places on the detrimental effect that those settings *can* have.
>> That would at least give you another angle to investigate.
>
> If there are specific things you’d like to know, I’ve be happy to be a
> human proxy. :)
I'd start with vm.* configuration, so the output from this:
# sysctl -a | grep '^vm.*'
and possibly /proc/meminfo. I'm especially interested in the overcommit
settings, because per the free output you provided there's ~16GB of free
RAM.
BTW what amounts of data are we talking about? How large is the database
and how large is the active set?
I also noticed you use kernel 3.2 - that's not the best kernel version
for PostgreSQL - see [1] or [2] for example.
[1]
https://medium.com/postgresql-talk/benchmarking-postgresql-with-different-linux-kernel-versions-on-u...
[2]
http://www.databasesoup.com/2014/09/why-you-need-to-avoid-linux-kernel-32.html
--
Tomas Vondra http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
--
Sent via pgsql-performance mailing list (pgsql-performance@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: tomas.vondra@2ndquadrant.com
Subject: Re: MusicBrainz postgres performance issues
In-Reply-To: <5505891B.6060800@2ndquadrant.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox