Re: Misleading panic message in backend/access/transam/xlog.c - Mailing list pgsql-hackers

From Michael Paquier
Subject Re: Misleading panic message in backend/access/transam/xlog.c
Date
Msg-id 20190110013832.GE2157@paquier.xyz
Whole thread Raw
In response to Re: Misleading panic message in backend/access/transam/xlog.c  (Andres Freund <andres@anarazel.de>)
Responses Re: Misleading panic message in backend/access/transam/xlog.c  (Robert Haas <robertmhaas@gmail.com>)
List pgsql-hackers
On Wed, Jan 09, 2019 at 05:09:19PM -0800, Andres Freund wrote:
> IIRC we have other such errors including offset and length (and if
> not we'll grow some). It should be formatted as a genetic write
> error with the file name, no reference to log file, etc, even if
> there's no precedent.

Yeah, there are a couple of them:
access/transam/xlog.c:
errmsg("could not read from log segment %s, offset %u: %m",
access/transam/xlog.c:
errmsg("could not read from log segment %s, offset %u: read %d of %zu",
access/transam/xlogutils.c:
errmsg("could not seek in log segment %s to offset %u: %m"
access/transam/xlogutils.c:
errmsg("could not read from log segment %s, offset %u, length %lu: %m",
replication/walreceiver.c:
errmsg("could not seek in log segment %s to offset %u: %m",
replication/walsender.c:
errmsg("could not seek in log segment %s to offset %u: %m",
replication/walsender.c:
errmsg("could not read from log segment %s, offset %u, length %zu: %m",
replication/walsender.c:
errmsg("could not read from log segment %s, offset %u: read %d of %zu",
--
Michael

Attachment

pgsql-hackers by date:

Previous
From: Andreas Karlsson
Date:
Subject: Re: Early WIP/PoC for inlining CTEs
Next
From: Donald Dong
Date:
Subject: Re: Making WAL receiver startup rely on GUC context forprimary_conninfo and primary_slot_name