Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1etBX3-0000Tz-Pa for pgsql-general@arkaria.postgresql.org; Tue, 06 Mar 2018 12:17:25 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1etBX2-0004SD-CE for pgsql-general@arkaria.postgresql.org; Tue, 06 Mar 2018 12:17:24 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1etBX2-0004S3-17 for pgsql-general@lists.postgresql.org; Tue, 06 Mar 2018 12:17:24 +0000 Received: from mx2.mailbox.org ([80.241.60.215]) by makus.postgresql.org with esmtps (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1etBWq-00065m-79 for pgsql-general@postgresql.org; Tue, 06 Mar 2018 12:17:22 +0000 Received: from smtp2.mailbox.org (smtp2.mailbox.org [80.241.60.241]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx2.mailbox.org (Postfix) with ESMTPS id 73AC641188; Tue, 6 Mar 2018 13:17:07 +0100 (CET) X-Virus-Scanned: amavisd-new at heinlein-support.de Received: from smtp2.mailbox.org ([80.241.60.241]) by spamfilter01.heinlein-hosting.de (spamfilter01.heinlein-hosting.de [80.241.56.115]) (amavisd-new, port 10030) with ESMTP id 4HhmeEEa0l6l; Tue, 6 Mar 2018 13:17:01 +0100 (CET) Message-ID: <1520338619.2601.26.camel@cybertec.at> Subject: Re: dirty_ratio & dirty_background_ratio settings with huge memory From: Laurenz Albe To: pinker , pgsql-general@postgresql.org Date: Tue, 06 Mar 2018 13:16:59 +0100 In-Reply-To: <1520331809441-0.post@n3.nabble.com> References: <1520331809441-0.post@n3.nabble.com> Organization: Cybertec Content-Type: text/plain; charset="UTF-8" Mime-Version: 1.0 Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk pinker wrote: > I've got cutomer with really huge RAM, now it's: > total used free shared buffers cached > Mem: 3102111 3052596 49515 208801 992 2961185 > -/+ buffers/cache: 90418 3011693 > Swap: 8191 1 8190 > > (free -m) > > and before it was twice more (6TB). > > and trying to figure out how to set dirty_ratio & dirty_background_ratio > parameters. Even for normal sized server those default sizes are to high, > but now would be ridiculously huge, respectively 1,24TB and 300GB. > I'm thinking about 1 percent for dirty_ratio and not using > dirty_background_ratio because it's not possible to set it below 1% but to > set dirty_background_bytes instead to about 1-2GB. > Maybe someone has got other experience with RAM of this size and those > settings? Yes, you should set vm.dirty_background_bytes and vm.dirty_bytes and not use the *_ratio settings. 2 GB for vm.dirty_background_bytes and 1 GB for vm.dirty_bytes sounds fine. Yours, Laurenz Albe -- Cybertec | https://www.cybertec-postgresql.com