public inbox for [email protected]  
help / color / mirror / Atom feed
From: Michael Paquier <[email protected]>
To: Hayato Kuroda (Fujitsu) <[email protected]>
Cc: 'Paul A Jungwirth' <[email protected]>
Cc: Mutaamba Maasha <[email protected]>
Cc: Amit Kapila <[email protected]>
Cc: David G. Johnston <[email protected]>
Cc: Zhijie Hou (Fujitsu) <[email protected]>
Cc: Tom Lane <[email protected]>
Cc: Bertrand Drouvot <[email protected]>
Cc: [email protected] <[email protected]>
Subject: Re: ReplicationSlotRelease() crashes when the instance is in the single user mode
Date: Wed, 20 Aug 2025 15:05:17 +0900
Message-ID: <[email protected]> (raw)
In-Reply-To: <OSCPR01MB14966F06D84A7A9C26570A519F530A@OSCPR01MB14966.jpnprd01.prod.outlook.com>
References: <CAA4eK1LK5nZUWwNY31X6BUXdQwwzpKGKxnw+zFf-cWKm3nuCEg@mail.gmail.com>
	<OSCPR01MB149669CFD736D48C4450337DDF5CD2@OSCPR01MB14966.jpnprd01.prod.outlook.com>
	<CAA4eK1L8_QrYavkCy9b0Rrz8gqZRQE8kEmv3g7Tz6tsN8YuvhA@mail.gmail.com>
	<OSCPR01MB149660CD4D6648CFE7FE68D34F5CC2@OSCPR01MB14966.jpnprd01.prod.outlook.com>
	<CA+renyWi+bbD8M8CDAaOMGbUrXptKLCK8zQWEhXy00PJuJqNuQ@mail.gmail.com>
	<OSCPR01MB14966B39B3ED21229EAEFA10FF531A@OSCPR01MB14966.jpnprd01.prod.outlook.com>
	<[email protected]>
	<OSCPR01MB14966D87D8EB0D9CD32C6A43DF530A@OSCPR01MB14966.jpnprd01.prod.outlook.com>
	<[email protected]>
	<OSCPR01MB14966F06D84A7A9C26570A519F530A@OSCPR01MB14966.jpnprd01.prod.outlook.com>

On Tue, Aug 19, 2025 at 12:52:24PM +0000, Hayato Kuroda (Fujitsu) wrote:
> I have run the tests on my CI and found that windows cannot accept the test.
> Per attached output, starting the postgres with the single-user mode was failed
> because the user had admin permissions [1]. However, pg_ctl start command could be
> done by the same user.
> I'm not familiar with Windows, but according to your blogpost [2], Windows seems
> to allows running some server command by generating the restricted context for
> running postgres commands. In case of single-user mode, however, we directly run
> the given command with the current user. So, there is a possibility that only
> instance can boot only by pg_ctl.
> Based on that, I want to skip the test on windows platform rather than modifying
> the ci environment.
> 
> IIUC, other tests which uses --single cannot work on windows as well.

This has reminded me of 1a9d80282811, where I have used a trick with
pg_ctl to allow single-user mode executions to bypass the privileged
account permission failure, but I don't see what we could do here as
we should pass down commands to postgres for execution via stdin for
IPC::Run.  We don't really have anything WIN32-specific, so skipping
the tests on Windows sounds fine by me.

One thing that you have forgotten is to update EXTRA_INSTALL to add
test_decoding, or a make check in the module fails.  I have expanded a
bit more the tests, as for example we have paths based on active_pid
for temporary slots, which could matter at some point.  I have added a
few more things with physical slots.

With all that in mind, I don't really see the point of 0002.  There
was also a mention of replication origins upthread, but we don't
really have anything specific to a shared state or a validation in
this area AFAIK, so I don't think that test additions are worth it in
this case. 
--
Michael


Attachments:

  [application/pgp-signature] signature.asc (833B, ../[email protected]/2-signature.asc)
  download

view thread (31+ messages)  latest in thread

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: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
  Subject: Re: ReplicationSlotRelease() crashes when the instance is in the single user mode
  In-Reply-To: <[email protected]>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox