Search Postgresql Archives

Re: pg_basebackup: return value 1: reason?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 04/16/2016 02:24 PM, Andrej Vanek wrote:
Hello,

my setup is:
1 master
1 synchronous slave (up and running)
2 asynchronous slave (up and running)
Now I'm setting up asynchronous slave: first step of this setup is
pg_basebackup connecting to master.

Indirections are because it is encapsulated in a script. This script is
aimed to serve for automated replication recovery. This script is
launched by crm_mon -d daemon.

You are right to check without indirections: now I tried to run the
command directly from command line without variables- it works fine...

This means: no problem in pg_basebackup itself

but some problem in environment of process launched from crm_mon daemon.
Thanks for your hint (remove indirections). Pg_basebackup works fine
when launched from command-line..
Unfortenutely I have still no clue how to solve the issue- su works. I

Is the su - even necessary?

pg_basebackup is a Postgres client program you can specify the user you want it to connect to using -U.

Or do you need the script to run as postgres in order to get permissions on wherever you are creating the backup directory?

have to find out why pg_basebackup cannot fork when launched from crm_mon.


I assume crm_mon is this:

http://linux.die.net/man/8/crm_mon

from Pacemaker.

I do not use Pacemaker, but I am pretty sure that running what is a monitoring program in daemon mode and then shelling out to another program is not workable. The docs seem to bear this out:

http://clusterlabs.org/wiki/PgSQL_Replicated_Cluster#Installation

https://github.com/smbambling/pgsql_ha_cluster/wiki/Building-A-Highly-Available-Multi-Node-PostgreSQL-Cluster

Best Regards, Andrej

2016-04-16 1:17 GMT+02:00 Adrian Klaver <adrian.klaver@xxxxxxxxxxx
<mailto:adrian.klaver@xxxxxxxxxxx>>:


--
Adrian Klaver
adrian.klaver@xxxxxxxxxxx


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



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux