0
votes
1answer
17 views

How the xlogs files travels form Master to Slave

I have some doubts about how the workflow proccess in PostgreSQL replication using archiving logs. If I have this configuration in Master postgresql.conf: archive_command = 'test ! -f ...
0
votes
2answers
26 views

for archive_command use an script rather than a command

I want to create a configuration to get a PostgreSQL HA. In my Master I want to configure a postgresql.conf file with this: archive_command = 'local_backup_script.sh "%p" "%f"' instead of: ...
2
votes
1answer
22 views

postgres: Database replica with some schemas writable

I have two computers. Computer A is dedicated to collecting data and storing it in its local database. Computer B is for analysis. A is running flat out just with the data collection, so I want to ...
0
votes
1answer
26 views

FDW, replication and CREATE SERVER - will it work?

We have two servers (master, slave) and we want to use the FDW. The two databases to be connected with the FDW are both on the master (and the slave of course). When we are to CREATE SERVER we would ...
0
votes
1answer
23 views

PostgreSQL replication with periodic log shipping

I'm using Windows Server 2008 R2 with 64-bit PostgreSQL 9.2 on both test machines. What I wish to achieve is that one server will be a master and other will be a slave. This is just for tests, finally ...
1
vote
1answer
34 views

What's the best solution for offline db syncing

I'm building a system which requires a master db (BIG master) that contains things like accounts, balances, actions, etc. This db then needs to be accessible at a physical place, like a fairground ...
3
votes
1answer
36 views

timeline 2 of the primary does not match recovery target timeline 1

I want to create a configuration with postgresql and pgpool to get height availability (HA). I want to do this: .-----. .--------. | | W | DB | | APP ...
0
votes
1answer
29 views

PostgreSQL synchronous replication time out?

I'm using PostgreSQL 9.3 with synchronous replication. I have 2 synchronous replicators and 1 async replicator. My problem is when 2 synchronous replicators are down, transaction will wait ...
0
votes
0answers
20 views

Which primary keys must be specified when using slony PostgreSQL replication?

I'm extremely green when it comes to databases, so forgive my ignorance. I've been researching ways to replicate our production Postgres DB, and I've decided to try out Slony. Since the server is ...
0
votes
0answers
22 views

Understanding correct procedure to recover master in master-slave replication in PostgreSQL

For learning, I have setup master-slave streaming synchronous replication. Pg-pool 3.3.3 is installed in one VM and it connect to 4 VMs which runs PostgreSQL 9.3, one master and 3 slaves. Replication ...
1
vote
1answer
29 views

Understanding pg-pool in details

I have following problem regarding the pg-pool (3.3.3) When master fails, automatic failover happens and standby is promoted to master. But this new master don't have any replicators. Other slave ...
0
votes
1answer
19 views

Does PostgreSQL take time to start streaming replication after restart master?

I set streaming replication in postgresql 9.3. I have one master and 3 slaves and replication works fine. But when i restart the master server and login using postgres database, pg_stat_replication ...
2
votes
0answers
76 views

Is there a way to replicate Postgres databases in Amazon RDS between regions?

We have a Postgres RDS instance in the AWS Oregon Region. For some supposed legal reasons, we have to host our client's European data in the Ireland AWS Region, but we need that data synchronized to ...
2
votes
1answer
100 views

Promotion of PostgreSQL standby and application reconnection

Background: I work for a small company. We have been using PostgreSQL on Heroku as one of our core technologies. While, in general, we've been happy with Heroku, the company has made the decision ...
0
votes
0answers
23 views

Postgres sync database

I have two postgres databases. Master = master_database Slave = database All initial changes are made to master. Upon admin approval, the version is updated, and I want all changes to be copied ...
3
votes
0answers
51 views

Postgres multidisk master replicating to single disk slave

I have an odd situation. I have a postgreSQL database master with multiple large tablespaces divided across 3 physical disks. I am setting up a slave that will be used to offload long, ...
2
votes
1answer
78 views

PostgreSQL Automatic Failover (Trigger File Creation)?

Is there a way to detect if the master PostgreSQL (9.3) server becomes unresponsive, and if so, create the trigger file (that is specified in recovery.conf) that initiates the failover process? Or ...
1
vote
1answer
67 views

Does PostgreSQL support multi-threaded replication?

Is PostgreSQL replication single-threaded ? Are there any tools to achieve multi-threaded replication ? I'm asking this since Mariadb support this and currently I'm learning both these dbs.
0
votes
1answer
37 views

Postgresql Chained Slaves and Slave Promotion

So I have a setup like Master -> Slave1 -> Slave2. Slave1 replicates from Master and Slave2 replicates from Slave1. If I promote Slave1 to master is it possible for Slave2 to continue replicating from ...
0
votes
2answers
159 views

trigger_file doesn't work

I set streaming replication. Replication works just fine but it doesn't care about trigger_file. I have nothing fancy there except all what many of tutorials advices: recovery.conf: standby_mode = ...
2
votes
1answer
33 views

How can I know whether postgres is currently running synchronous or asynchronous replication?

I see from ps that: postgres: wal sender process replicator X.X.X.X(38681) streaming 0/17AF5438 But is there any way for me to know whether it is synchronous or asynchronous? I made the relevant ...
3
votes
1answer
95 views

Can Postgres synchronous replication stall a cluster if secondary/standby crashes?

In a setup with Postgres synchronous replication, let's say one of the secondary/standby machines crashes, will that lock/halt the master? That is, since the Postgres master always waits for ...
8
votes
1answer
103 views

How do data checksums interact with streaming replication?

Data checksums are a new feature introduced in 9.3, and: there is a new GUC parameter "ignore_checksum_failure" which will force PostgreSQL to continue processing a transaction even if corruption ...
0
votes
1answer
60 views

PostgreSQL replication with fsync disabled?

I need to run PostgreSQL in-memory (for performance reasons), so I intend to disable fsync, which means that no writes will be sent to the WAL. However, as part of my scheme to meet another ...
0
votes
1answer
120 views

Postgres live backup

Goal: Maintaining a constant live backup of a postgres cluster. In case of cluster failure, backup/Secondary will contain most up to date view of Primary cluster. This is not a hot standby ...
0
votes
0answers
47 views

PostgreSQL manual way of sharding like behaviour

I've a main server with low space available and good internet connection that has a postgres database in production for a zabbix system. Also, I've another secundary server plenty of space but with ...
0
votes
0answers
71 views

Mirror database on same server instance for better read performance?

I am developing a somewhat big web application, which uses data which is aggregated using a crawler. The crawler is constantly writing to the database and updates many tables at the same time. For the ...
1
vote
0answers
56 views

PostgreSQL 9.3 slaves don't recognize hstore as a type

I am using the postgres built in replication with two slave nodes and a single master. On the master node (as well as the slaves) the hstore extension is installed. But whenever a query using hstore ...
2
votes
2answers
314 views

postgreSQL 9.3 streaming replication delay

I'm running a fairly simple WAL streaming replication setup between two postgreSQL 9.3 servers that are on a private 1Gb LAN, but recently I've noticed that there is an increasing amount of ...
1
vote
1answer
143 views

Sync postgreSQL with SQL Server database- on data change event

I have one PostgreSQL database and its data are being changed regularly. I want to sync all its data with my SQL Server database. One thing I can do is use query to check all required tables and ...
2
votes
0answers
44 views

Postgres Replication From Different Masters?

I'm getting a Postgres 9.3.3 install sorted out. My application is Drupal (so read/write), but low-traffic, so all application traffic is sent to the primary master. I have two sites (main and ...
0
votes
1answer
54 views

Change posgresql 9.3 slave roll password

I need to change the password on my slave posgresql server, because the person who set it up left the password the same as the password for the super user account on our other server. When I run ...
1
vote
0answers
92 views

Data Corruption on base backups created with wal-e?

I have streaming replication setup on Postgresql 9.1 with two machines on AWS EC2. The master has a cron job that does a daily base backup using the wal-e tool and uploading it to Amazon's S3 storage. ...
3
votes
2answers
401 views

Postgres Streaming Replication lagging, using lots of CPU and little I/O

We have 2 dedicated DB Servers. One is master and other is its streaming slave. Postgres version 9.0.17. We have similar hardware on both servers and using 15krpm SAS drive in Raid 10 for Database ...
0
votes
0answers
42 views

Is there a way to synchronise 2 postgresql server that may be deconnected and modified?

I would like to know if there is a way to use a cluster / replication mecanism that can manager deconnection and modification while deconnected. Say I have server A and B, they see each over, cluster ...
1
vote
1answer
39 views

Preparing a former master to run as slave again

I have a streaming replication setup using postgresql 9.3. I have two servers, the master (server_1) and the slave (server_2). The other day I did a failover to my slave (server_2). Now server_2 has ...
1
vote
1answer
27 views

Suggested ways to route traffic between master / slave

I have multiple Postgres servers up, running in master / slave streaming replication mode. I was wondering what the suggested methods of routing write traffic to the master, and the read traffic to ...
3
votes
2answers
388 views

Replicating some tables from one postgres database to another

I've got the following situation: I have three machines running postgresql databases. One machine holds client account information (call this machine C), the other two machines hold client logging ...
3
votes
2answers
140 views

How can streaming replication be kept lagged by a certain 'delay' time?

Postgres has had streaming replication since 9.0 and since 9.1 it is possible to pause and resume the application of the streamed WAL records using pg_xlog_replay_pause() and pg_xlog_replay_resume(). ...
2
votes
2answers
468 views

Streaming Replication Log is puzzling me

I have a streaming replication hot-standby setup, which seems to be running all good. I can login, execute selects and the result seems to be up-to-date with the master. However in the log of the ...
0
votes
1answer
337 views

Streaming replication between postgresql 9.2 and 9.3

Does anyone know if it's problematic to have a postgresql 9.3 slave setup to do streaming replication from a postgresql 9.2 master?
0
votes
1answer
196 views

pgpool2 not working on my Ubuntu i686 athlon i386 GNU/Linux

I am trying to implement replication and load balancing on my Ubuntu i686 athlon i386 GNU/Linux.for creating database clustures I have installed postgresql contrib 9.1.11 having initially database ...
2
votes
1answer
181 views

Postgresql 9.2.6 ignoring archive_command

I'm attempting to set up a 3-server chain by leveraging WAL-E. I've done this in the past with replication/wal segments and I'm attempting the exact same method, just with using WAL-E in between. My ...
1
vote
1answer
526 views

Postgres replication: Do I need to rsync pg_xlog files if I have archiving setup in master?

I am trying to replicate a master to slave, without shutting down my master. In the tutorial here: http://wiki.postgresql.org/wiki/Binary_Replication_Tutorial, they recommend these steps: ...
1
vote
0answers
201 views

Postgres database zero down time production deployment

I need some idea about how I can deploy a financial application in production environment using PostgreSQL DB with zero down time. I have two servers in Master-Slave design. Currently I am giving ...
1
vote
1answer
100 views

Postgresql wal saving for standby servers that go offline

I use postgresql 9.1 replication to a lot of workstations that have postgresql on hot standby mode. However sometimes these workstations go offline and disconnect from the master server. If they go ...
2
votes
1answer
157 views

Postgres: Purpose of archiving in master?

I am reading tutorials on how to setup streaming replication in Postgres from master to slave. Some tutorials recommend setting up archiving in the master (and restoring in slave) . In the master, ...
4
votes
1answer
1k views

How to configure replication from PostgreSQL (RDS) to vanilla PostgreSQL?

I have an Amazon RDS Postgres DB and I created a "replicator" user and granted it the "replication" privilege. db=> create role replicator login password 'something'; CREATE ROLE db=> alter ...
1
vote
1answer
146 views

Postgres streaming replication to a different schema on another server?

We've got a system with about a dozen Postgres 9.3 databases representing a dozen different applications. In order to do reporting across systems, we have a script that dumps each database and loads ...
6
votes
1answer
185 views

Can we use old primary to sync with standby after failover in PostgreSQL?

If my standby (postgres) is behind by few seconds before failover. What is the easiest way to sync back my old primary after failover in PostgreSQL. In Oracle we have the option of Reinstating a ...