Skip to content

Commit 05294dc

Browse files
authored
Backport: Doc update for HA v14 from 3df907c (#790)
1 parent 3bf54bd commit 05294dc

File tree

2 files changed

+31
-45
lines changed

2 files changed

+31
-45
lines changed

docs/solutions/ha-setup-apt.md

Lines changed: 17 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -354,33 +354,19 @@ Run the following commands on all nodes. You can do this in parallel:
354354
archive_mode: "on"
355355
archive_timeout: 600s
356356
archive_command: "cp -f %p /home/postgres/archived/%f"
357+
pg_hba:
358+
- local all all peer
359+
- host replication replicator 127.0.0.1/32 trust
360+
- host replication replicator 192.0.0.0/8 scram-sha-256
361+
- host all all 0.0.0.0/0 scram-sha-256
362+
recovery_conf:
363+
restore_command: cp /home/postgres/archived/%f %p
357364
358365
# some desired options for 'initdb'
359-
initdb: # Note: It needs to be a list (some options need values, others are switches)
360-
- encoding: UTF8
361-
- data-checksums
362-
363-
pg_hba: # Add following lines to pg_hba.conf after running 'initdb'
364-
- host replication replicator 127.0.0.1/32 trust
365-
- host replication replicator 0.0.0.0/0 md5
366-
- host all all 0.0.0.0/0 md5
367-
- host all all ::0/0 md5
368-
369-
# Additional script to be launched after initial cluster creation (will be passed the connection URL as parameter)
370-
# post_init: /usr/local/bin/setup_cluster.sh
371-
# Some additional users users which needs to be created after initializing new cluster
372-
users:
373-
admin:
374-
password: qaz123
375-
options:
376-
- createrole
377-
- createdb
378-
percona:
379-
password: qaz123
380-
options:
381-
- createrole
382-
- createdb
383-
366+
initdb: # Note: It needs to be a list (some options need values, others are switches)
367+
- encoding: UTF8
368+
- data-checksums
369+
384370
postgresql:
385371
cluster_name: cluster_1
386372
listen: 0.0.0.0:5432
@@ -402,6 +388,12 @@ Run the following commands on all nodes. You can do this in parallel:
402388
basebackup:
403389
checkpoint: 'fast'
404390
391+
watchdog:
392+
mode: required # Allowed values: off, automatic, required
393+
device: /dev/watchdog
394+
safety_margin: 5
395+
396+
405397
tags:
406398
nofailover: false
407399
noloadbalance: false

docs/solutions/ha-setup-yum.md

Lines changed: 14 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -366,31 +366,19 @@ Run the following commands on all nodes. You can do this in parallel:
366366
archive_mode: "on"
367367
archive_timeout: 600s
368368
archive_command: "cp -f %p /home/postgres/archived/%f"
369+
pg_hba:
370+
- local all all peer
371+
- host replication replicator 127.0.0.1/32 trust
372+
- host replication replicator 192.0.0.0/8 scram-sha-256
373+
- host all all 0.0.0.0/0 scram-sha-256
374+
recovery_conf:
375+
restore_command: cp /home/postgres/archived/%f %p
369376
370377
# some desired options for 'initdb'
371378
initdb: # Note: It needs to be a list (some options need values, others are switches)
372379
- encoding: UTF8
373380
- data-checksums
374-
375-
pg_hba: # Add following lines to pg_hba.conf after running 'initdb'
376-
- host replication replicator 127.0.0.1/32 trust
377-
- host replication replicator 0.0.0.0/0 md5
378-
- host all all 0.0.0.0/0 md5
379-
- host all all ::0/0 md5
380-
381-
# Some additional users which needs to be created after initializing new cluster
382-
users:
383-
admin:
384-
password: qaz123
385-
options:
386-
- createrole
387-
- createdb
388-
percona:
389-
password: qaz123
390-
options:
391-
- createrole
392-
- createdb
393-
381+
394382
postgresql:
395383
cluster_name: cluster_1
396384
listen: 0.0.0.0:5432
@@ -413,6 +401,12 @@ Run the following commands on all nodes. You can do this in parallel:
413401
basebackup:
414402
checkpoint: 'fast'
415403
404+
watchdog:
405+
mode: required # Allowed values: off, automatic, required
406+
device: /dev/watchdog
407+
safety_margin: 5
408+
409+
416410
tags:
417411
nofailover: false
418412
noloadbalance: false

0 commit comments

Comments
 (0)