Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jfhzo-0000eZ-Np for pgsql-admin@arkaria.postgresql.org; Mon, 01 Jun 2020 10:48:44 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jfhzn-0004pb-LT for pgsql-admin@arkaria.postgresql.org; Mon, 01 Jun 2020 10:48:43 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jfhzn-0004pU-EG for pgsql-admin@lists.postgresql.org; Mon, 01 Jun 2020 10:48:43 +0000 Received: from hermes.gatewaynet.com ([193.92.121.98]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jfhzl-0002Sz-4q for pgsql-admin@lists.postgresql.org; Mon, 01 Jun 2020 10:48:42 +0000 Received: from smadev.internal.net (pc131.internal.net [10.9.200.131]) by hermes.gatewaynet.com (8.15.2/8.15.2/Debian-8) with ESMTPS id 051AmX7o021041 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Mon, 1 Jun 2020 13:48:38 +0300 Received: from smadev.internal.net (smadev [10.9.200.131]) by smadev.internal.net (8.15.2/8.15.2) with ESMTP id 051AmXWN018349 for ; Mon, 1 Jun 2020 13:48:33 +0300 (EEST) (envelope-from achill@matrix.gatewaynet.com) Subject: Re: pg_stat_database.xact_commit + pg_stat_database.xact_rollback as a reliable metric for xid consumption ? To: pgsql-admin@lists.postgresql.org References: <51fa222b-374e-39da-eb8c-66d667426bae@matrix.gatewaynet.com> From: Achilleas Mantzios Message-ID: <36dd7ae2-7c6f-86af-430b-dd9a0f7774b3@matrix.gatewaynet.com> Date: Mon, 1 Jun 2020 13:48:33 +0300 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:60.0) Gecko/20100101 Thunderbird/60.3.2 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-Virus-Scanned: clamav-milter 0.101.4 at hermes X-Virus-Status: Clean X-Spam-Status: No, score=-36.0 required=5.0 tests=ALL_TRUSTED,DYN_HAM_COORD, DYN_HAM_IT,DYN_HAM_IT_PARTNERS,DYN_HAM_NAUTICAL,DYN_SPAM_SUBJ autolearn=unavailable autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on hermes.gatewaynet.com List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 1/6/20 1:36 μ.μ., Julien Rouhaud wrote: > On Mon, Jun 1, 2020 at 12:02 PM Achilleas Mantzios > wrote: > Because read only transaction usually don't consume an xid. So yes > pg_stat_database gives a more reasonable approximation of the real > number of transactions happening on the server. Thank you, so what would be the official way to monitor txid consumption (from a MVCC / Freezing admin POV)? > > -- Achilleas Mantzios IT DEV Lead IT DEPT Dynacom Tankers Mgmt