pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michael Paquier <michael@paquier.xyz>
To: Postgres hackers <pgsql-hackers@postgresql.org>
Cc: Andrew Dunstan <andrew@dunslane.net>
Subject: Re: pgsql: Switch pg_verify_checksums back to a blacklist
Date: Fri, 30 Nov 2018 14:35:55 +0900
Message-ID: <20181130053555.GF2267@paquier.xyz> (raw)
In-Reply-To: <E1gSXjX-0003Oc-VK@gemulon.postgresql.org>
References: <E1gSXjX-0003Oc-VK@gemulon.postgresql.org>

On Fri, Nov 30, 2018 at 01:36:43AM +0000, Michael Paquier wrote:
> Switch pg_verify_checksums back to a blacklist
> 
> This basically reverts commit d55241af705667d4503638e3f77d3689fd6be31,
> leaving around a portion of the regression tests still adapted with
> empty relation files, and corrupted cases.  This is also proving to be
> failing to check properly relation files located in a non-default
> tablespace path.

So, jacana is not in love with this commit for the tests:
https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=jacana&dt=2018-11-30%2003%3A34%3A23

The error is here:
server started
# Postmaster PID for node "node_checksum" is 14820
error running SQL: 'psql:<stdin>:1: ERROR:  directory
"/home/pgrunner/bf/root/HEAD/pgsql.build/src/bin/pg_verify_checksums/tmp_check/t_002_actions_node_checksum_data/ts_corrupt_dir"
does not exist'

What visibly happens is that we create a path for a tablespace which
will include a corrupted table.  However psql tries to run CREATE
TABLESPACE but gets back a complain about the path not existing.  The
thing is that mkdir has been used beforehand so the path should be
here.

I have tested this set of TAP tests on my Windows 10 VM with MSVC 2015
before commit and those tests passed.  Could it be that jacana is using
msys, so a trick similar to what is used in 014_unlogged_reinit.pl is
necessary?

Andrew, could you confirm if the patch attached works?  I would prefer
not doing a blind fix if possible..
--
Michael

Attachments:

verify-checksum-tap-msys.patch (text/x-diff, 935B) download diff --git a/src/bin/pg_verify_checksums/t/002_actions.pl b/src/bin/pg_verify_checksums/t/002_actions.pl index 12cca604e6..181f58f67c 100644 --- a/src/bin/pg_verify_checksums/t/002_actions.pl +++ b/src/bin/pg_verify_checksums/t/002_actions.pl @@ -113,11 +113,10 @@ command_fails(['pg_verify_checksums', '-D', $pgdata], check_relation_corruption($node, 'corrupt1', 'pg_default'); # Create tablespace to check corruptions in a non-default tablespace. -my $basedir = $node->basedir; -my $tablespace_dir = "$basedir/ts_corrupt_dir"; -mkdir ($tablespace_dir); +my $tablespaceDir = TestLib::tempdir; +my $realTSDir = TestLib::real_dir($tablespaceDir); $node->safe_psql('postgres', - "CREATE TABLESPACE ts_corrupt LOCATION '$tablespace_dir';"); + "CREATE TABLESPACE ts_corrupt LOCATION '$realTSDir';"); check_relation_corruption($node, 'corrupt2', 'ts_corrupt'); # Utility routine to check that pg_verify_checksums is able to detect
signature.asc (application/pgp-signature, 832B) download

view thread (6+ messages)  latest in thread

Message-ID: <20181130053555.GF2267@paquier.xyz>
Permalink:  ../20181130053555.GF2267@paquier.xyz/
Also on:    postgresql.org/message-id/20181130053555.GF2267@paquier.xyz

 ·  · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: michael@paquier.xyz, pgsql-hackers@postgresql.org, andrew@dunslane.net
  Subject: Re: pgsql: Switch pg_verify_checksums back to a blacklist
  In-Reply-To: <20181130053555.GF2267@paquier.xyz>
  References: <E1gSXjX-0003Oc-VK@gemulon.postgresql.org> <20181130053555.GF2267@paquier.xyz>

* 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