pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Laurenz Albe <laurenz.albe@cybertec.at>
To: Yi Sun <yinan81@gmail.com>
To: pgsql-performance@lists.postgresql.org
Subject: Re: overcommit_ratio setting
Date: Mon, 14 Jun 2021 18:18:23 +0200
Message-ID: <8f67083bf8fee0c8af858d1b47b6505ebb106c93.camel@cybertec.at> (raw)
In-Reply-To: <CABWY_HCTBwZY-dQNX-XweBz3XYfuCwXcyggo8H3YbW4EUQKOdQ@mail.gmail.com>
References: <CABWY_HCTBwZY-dQNX-XweBz3XYfuCwXcyggo8H3YbW4EUQKOdQ@mail.gmail.com>

On Mon, 2021-06-14 at 18:16 +0800, Yi Sun wrote:
> After checking doc, only mentioned vm.overcommit_memory=2, but didn't mentioned vm.overcommit_ratio recommended value
> https://www.postgresql.org/docs/11/kernel-resources.html#LINUX-MEMORY-OVERCOMMIT
> some articles mentioned that 80 or 90 configuration in their env
> So is it OK just to configure  vm.overcommit_ratio to 90 please?

It depends on the size of RAM and swap space:

overcommit_ratio < (RAM - swap) / RAM * 100

Here, RAM is the RAM available to PostgreSQL.

Yours,
Laurenz Albe
-- 
Cybertec | https://www.cybertec-postgresql.com






view thread (6+ messages)  latest in thread

Message-ID: <8f67083bf8fee0c8af858d1b47b6505ebb106c93.camel@cybertec.at>
Permalink:  ../8f67083bf8fee0c8af858d1b47b6505ebb106c93.camel@cybertec.at/
Also on:    postgresql.org/message-id/8f67083bf8fee0c8af858d1b47b6505ebb106c93.camel@cybertec.at

 · 

reply

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: laurenz.albe@cybertec.at, yinan81@gmail.com, pgsql-performance@lists.postgresql.org
  Subject: Re: overcommit_ratio setting
  In-Reply-To: <8f67083bf8fee0c8af858d1b47b6505ebb106c93.camel@cybertec.at>

* 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