pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedpostgresql checking return status of archive_command?
3+ messages / 3 participants
[nested] [flat]
* postgresql checking return status of archive_command?
@ 2014-07-11 14:01 John Scalia <jayknowsunix@gmail.com>
2014-07-11 14:04 ` Re: postgresql checking return status of archive_command? Devrim Gündüz <devrim@gunduz.org>
0 siblings, 1 reply; 3+ messages in thread
From: John Scalia @ 2014-07-11 14:01 UTC (permalink / raw)
To: pgsql-admin
hi all,
First off, my thanks to everyone who responded to my last post regarding copying WAL segments to 2 standby servers. My script is working wonderfully now, but I have a followup
question like the subject line. Does postgresql or any of its child processes check the return code of the command executed in the archive_command and does it log anything if that
return code is NOT zero? I've been trying to think of easy ways to force an error to test, but thought I'd ask first.
TIA,
Jay
--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: postgresql checking return status of archive_command?
2014-07-11 14:01 postgresql checking return status of archive_command? John Scalia <jayknowsunix@gmail.com>
@ 2014-07-11 14:04 ` Devrim Gündüz <devrim@gunduz.org>
2014-07-14 02:20 ` Re: postgresql checking return status of archive_command? Craig Ringer <craig@2ndquadrant.com>
0 siblings, 1 reply; 3+ messages in thread
From: Devrim Gündüz @ 2014-07-11 14:04 UTC (permalink / raw)
To: John Scalia <jayknowsunix@gmail.com>; +Cc: pgsql-admin
Hi,
On Fri, 2014-07-11 at 10:01 -0400, John Scalia wrote:
> Does postgresql or any of its child processes check the return code of
> the command executed in the archive_command and does it log anything
> if that return code is NOT zero? I've been trying to think of easy
> ways to force an error to test, but thought I'd ask first.
It does. It will throw an error to log file, if the return code is
non-zero.
Regards,
--
Devrim GÜNDÜZ
Principal Systems Engineer @ EnterpriseDB: http://www.enterprisedb.com
PostgreSQL Danışmanı/Consultant, Red Hat Certified Engineer
Twitter: @DevrimGunduz , @DevrimGunduzTR
Attachments:
signature.asc (application/pgp-signature, 818B) download
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: postgresql checking return status of archive_command?
2014-07-11 14:01 postgresql checking return status of archive_command? John Scalia <jayknowsunix@gmail.com>
2014-07-11 14:04 ` Re: postgresql checking return status of archive_command? Devrim Gündüz <devrim@gunduz.org>
@ 2014-07-14 02:20 ` Craig Ringer <craig@2ndquadrant.com>
0 siblings, 0 replies; 3+ messages in thread
From: Craig Ringer @ 2014-07-14 02:20 UTC (permalink / raw)
To: Devrim Gündüz <devrim@gunduz.org>; John Scalia <jayknowsunix@gmail.com>; +Cc: pgsql-admin
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 07/11/2014 10:04 PM, Devrim Gündüz wrote:
> It does. It will throw an error to log file, if the return code is
> non-zero.
One thing to watch out for is the unfortunate behaviour of pipe error
handling, though. You want to
set -o pipefail
if you're using pipes.
- --
Craig Ringer http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
iQEcBAEBAgAGBQJTwz5EAAoJELBXNkqjr+S2yxcH/jLNX/gqeb3mruemnP6wL5eQ
mJxXq2EUcreyJcUuuE5PqtUtDUZUbqHtfcO+NQkloKDrJ6Oo8YNm7NCVWCBrfqdV
bSCOIJaT6fosZIUY6GlqJXfSI7YZ98FZexXCb1B/r0cQU2NJXqOY9DS/Hae2RDSP
qA83t4dl4boqC46I+s9qjIDKeDr8weXDHzA2Cv8D+nZpOY1ieoC8k98hE+2jJkcN
Lyp+eVhPBaI+Puj8Tp5b5vvXGh1uFQjM73hufNk1QFLvPCpeca/1nzMQ+2FZQXx4
eQDSrC5c2NTFpjikXHxmljfqhzan+XixAhJpMWpIxgCzzwGWIHHtZJvfYcl+ofs=
=ETgw
-----END PGP SIGNATURE-----
--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin
^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2014-07-14 02:20 UTC | newest]
Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2014-07-11 14:01 postgresql checking return status of archive_command? John Scalia <jayknowsunix@gmail.com>
2014-07-11 14:04 ` Devrim Gündüz <devrim@gunduz.org>
2014-07-14 02:20 ` Craig Ringer <craig@2ndquadrant.com>
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