Scott Marlowe wrote:
> On Fri, Aug 18, 2017 at 12:40 PM, twoflower <standa.ku...@gmail.com> wrote:
> > I changed my archive_command to the following:
> >
> > archive_command = 'gsutil cp /storage/postgresql/9.6/main/%p
> > gs://my_bucket/pg_xlog/'

> > 2017-08-18 18:34:25.057 GMT [1436][0]: [104321] WARNING:  archiving
> > transaction log file "000000010000038B000000D8" failed too many times, will
> > try again later

> Sounds like it depends on some envvar it doesn't see when run from the
> postmaster. If you sudo -u postgres and run it does it work?

I saw one installation with "gsutil cp" in archive_command recently.  It
had the CLOUDSDK_PYTHON environment variable set in the archive_command
itself.  Maybe that's a problem.

Another possible problem might be the lack of %f (this command seems to
rely on the file being the same name at the other end, which isn't
necessarily so)  and the fact that %p is supposed to be the path of the
file, so you shouldn't qualify it with the full path.

-- 
Álvaro Herrera                https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

Reply via email to