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 1f1qg6-0000f2-Vr for pgsql-general@arkaria.postgresql.org; Fri, 30 Mar 2018 09:50:35 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1f1qg5-00079y-9N for pgsql-general@arkaria.postgresql.org; Fri, 30 Mar 2018 09:50:33 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f1qg5-00079p-1c for pgsql-general@lists.postgresql.org; Fri, 30 Mar 2018 09:50:33 +0000 Received: from ppp-2-84-221-32.home.otenet.gr ([2.84.221.32] helo=smadev.internal.net) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f1qg2-0008O7-A4 for pgsql-general@lists.postgresql.org; Fri, 30 Mar 2018 09:50:32 +0000 Received: from smadev.internal.net (smadev [10.9.200.131]) by smadev.internal.net (8.15.2/8.15.2) with ESMTP id w2U9oPXG025839 for ; Fri, 30 Mar 2018 12:50:25 +0300 (EEST) (envelope-from achill@matrix.gatewaynet.com) From: Achilleas Mantzios Subject: Re: Question about buffers_alloc in pg_stat_bgwriter view for monitoring To: pgsql-general@lists.postgresql.org References: <1a00e942-e7c6-8e4d-afec-4b1befd5688d@pro-open.de> Message-ID: Date: Fri, 30 Mar 2018 12:50:25 +0300 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 29/03/2018 20:24, Alvar Freude wrote: > Hi, > >> Am 29.03.2018 um 10:30 schrieb Gunnar Nick Bluth : >> >> Thus, buffer_alloc is the global count of buffers allocated in the >> cluster. That it appears in the bgwriter statistics is more or less >> coincidental. > But it seems not to be the total shared_buffers used, but the total number of allocated and re-allocated buffers. So it increments every time a buffer is allocated. Maybe I’m the only one who misunderstands it – or someone with better english then me should update the docs. ;-) > But shared_buffers represents the max no of postgresql buffers, per server, at any given time. It is a limit (constant) not a metric. The count of all concurrent buffers at any given time must be less than shared_buffers. So my question is : Does buffer_alloc represent the total read/write traffic of the database since the last reset? > > Ciao > Alvar > > -- > Alvar C.H. Freude | http://alvar.a-blast.org > https://blog.alvar-freude.de/ > https://www.wen-waehlen.de/ -- Achilleas Mantzios IT DEV Lead IT DEPT Dynacom Tankers Mgmt