Re: How to start slave after pg_basebackup. Why min_wal_size and wal_keep_segments are duplicated

From: "Andrus" <kobruleht2(at)hot(dot)ee>
To: "pgsql-general" <pgsql-general(at)postgresql(dot)org>, "Adrian Klaver" <adrian(dot)klaver(at)aklaver(dot)com>
Subject: Re: How to start slave after pg_basebackup. Why min_wal_size and wal_keep_segments are duplicated
Date: 2020-06-01 05:50:38
Message-ID: 74A42D0ECD334244813128ADE21A2DD4@dell2
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi!

>> I want to create hot standby async server using
>> /etc/init.d/postgresql stop
>> mv /var/lib/postgresql/12/main /var/lib/postgresql/12/mainold
>> pg_basebackup --write-recovery-conf -D /var/lib/postgresql/12/main
>I don't see where the base backup is being taken from just where it is going.

It is taken from VPS server over 20 Mbit public internet connection.
Both servers are running Debian Linux.

>> I dont receive WALs.
>If you are doing binary replication then you are receiving WALs. It just a matter of whether you are streaming them or shipping
>them over complete.

Using wal_keep_segments=360 also causes same wal file not found error after pg_basebackup.
master server has 6GB wal files. wal log during pg_basebackup is much slower than 360.
Maybe pg_basebackup skips wal segments . Maybe using wal_compression=on causes the issue.

How to fix this ?
How to create base backup so that cluster is tranferred over internet faster? Maybe it can transferred in compressed form over
internet.

Andrus.

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Tanja Savic 2020-06-01 07:04:51 RE: pg_ctl can't start db server
Previous Message Stefan Knecht 2020-06-01 05:36:14 Re: Oracle vs. PostgreSQL - a comment