pg.ddx.io pgsql-hackers@postgresql.org mailing list archive
help / color / mirror / Atom feed From: Andres Freund <andres@anarazel.de>
To: Fujii Masao <masao.fujii@oss.nttdata.com>
Cc: Masahiro Ikeda <ikedamsh@oss.nttdata.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: Add statistics to pg_stat_wal view for wal related parameter tuning
Date: Mon, 21 Dec 2020 16:39:35 -0800
Message-ID: <20201222003935.47aoxfmokltlrlf2@alap3.anarazel.de> (raw )
In-Reply-To: <20201221211650.k7b53tcnadrciqjo@alap3.anarazel.de >
References: <e3135545ffe792d6d636ebc40ebf022d@oss.nttdata.com >
<e28c5f5e-363e-70c1-a200-28a8798ed8e2@oss.nttdata.com >
<11e81f0b7d90dd69077d3d964a9a4da9@oss.nttdata.com >
<79620b5c-ecf1-3d4f-80b5-7e311b7a0662@oss.nttdata.com >
<89de5056627ebdd144967959bd789bd6@oss.nttdata.com >
<58ccc451-8429-ce44-f0b7-773c8dfedf45@oss.nttdata.com >
<7eb4ebd487b53200bde98ba2f0a7e789@oss.nttdata.com >
<f9197102-4cb4-dfb6-02a4-b8e237c7699f@oss.nttdata.com >
<451365b7-9e22-211e-428f-fc90ebc715bc@oss.nttdata.com >
<20201221211650.k7b53tcnadrciqjo@alap3.anarazel.de >
Hi,
On 2020-12-21 13:16:50 -0800, Andres Freund wrote:
> On 2020-12-02 13:52:43 +0900, Fujii Masao wrote:
> > Pushed. Thanks!
>
> Why are wal_records/fpi long, instead of uint64?
> long wal_records; /* # of WAL records produced */
> long wal_fpi; /* # of WAL full page images produced */
> uint64 wal_bytes; /* size of WAL records produced */
>
> long is only 4 byte e.g. on windows, and it is entirely possible to wrap
> a 4 byte record counter. It's also somewhat weird that wal_bytes is
> unsigned, but the others are signed?
>
> This is made doubly weird because on the SQL level you chose to make
> wal_records, wal_fpi bigint. And wal_bytes numeric?
Some more things:
- There's both PgStat_MsgWal WalStats; and static PgStat_WalStats walStats;
that seems *WAY* too confusing. And the former imo shouldn't be
global.
- AdvanceXLInsertBuffer() does WalStats.m_wal_buffers_full, but as far
as I can tell there's nothing actually sending that?
- Andres
view thread (33+ messages) latest in thread
Message-ID: <20201222003935.47aoxfmokltlrlf2@alap3.anarazel.de>
Permalink: ../20201222003935.47aoxfmokltlrlf2@alap3.anarazel.de/
Also on: postgresql.org/message-id/20201222003935.47aoxfmokltlrlf2@alap3.anarazel.de
copy link · copy postgr.es
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-hackers@postgresql.org
Cc: andres@anarazel.de, masao.fujii@oss.nttdata.com, ikedamsh@oss.nttdata.com
Subject: Re: Add statistics to pg_stat_wal view for wal related parameter tuning
In-Reply-To: <20201222003935.47aoxfmokltlrlf2@alap3.anarazel.de>
* 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