Add PostgreSQL HA OCF agent modular baseline

This commit is contained in:
Lyncoln
2026-09-12 01:28:33 -04:00
commit 4a358ae0f6
30 changed files with 7119 additions and 0 deletions
+34
View File
@@ -0,0 +1,34 @@
totem {
version: 2
cluster_name: postgres-ra-test
transport: knet
crypto_cipher: aes256
crypto_hash: sha256
cluster_uuid: 58bac4b5a81c4bae904d5f719bdb88b7
}
nodelist {
node {
ring0_addr: 192.168.1.6
name: DAVID-ELITEDESK
nodeid: 1
}
node {
ring0_addr: 192.168.1.2
name: DAVID-DV6
nodeid: 2
}
}
quorum {
provider: corosync_votequorum
two_node: 1
}
logging {
to_logfile: yes
logfile: /var/log/cluster/corosync.log
to_syslog: yes
timestamp: on
}
+8
View File
@@ -0,0 +1,8 @@
Cluster Properties: cib-bootstrap-options
cluster-infrastructure=corosync
cluster-name=postgres-ra-test
dc-version=3.0.2-1.fc43-61983e8
fencing-enabled=false
have-watchdog=false
last-lrm-refresh=1789180342
maintenance-mode=true
@@ -0,0 +1,29 @@
Clone: pg-ha-clone
Meta Attributes: pg-ha-clone-meta_attributes
clone-max=2
clone-node-max=1
notify=true
promotable=true
promoted-max=1
promoted-node-max=1
Resource: pg-ha (class=ocf provider=loxthelion type=managed-container)
Attributes: pg-ha-instance_attributes
container_name=postgres
db_name=david
db_user=david
pg_os_user=postgres
service_name=postgres.service
service_user=david
Operations:
demote: pg-ha-demote-interval-0s
interval=0s timeout=60s
monitor: pg-ha-monitor-interval-11s
interval=11s timeout=20s role=Promoted
promote: pg-ha-promote-interval-0s
interval=0s timeout=60s
start: pg-ha-start-interval-0s
interval=0s timeout=60s
stop: pg-ha-stop-interval-0s
interval=0s timeout=60s
monitor: pg-ha-monitor-interval-10s
interval=10s timeout=20s role=Unpromoted
+21
View File
@@ -0,0 +1,21 @@
Resource: pg-ha (class=ocf provider=loxthelion type=managed-container)
Attributes: pg-ha-instance_attributes
container_name=postgres
db_name=david
db_user=david
pg_os_user=postgres
service_name=postgres.service
service_user=david
Operations:
demote: pg-ha-demote-interval-0s
interval=0s timeout=60s
monitor: pg-ha-monitor-interval-11s
interval=11s timeout=20s role=Promoted
promote: pg-ha-promote-interval-0s
interval=0s timeout=60s
start: pg-ha-start-interval-0s
interval=0s timeout=60s
stop: pg-ha-stop-interval-0s
interval=0s timeout=60s
monitor: pg-ha-monitor-interval-10s
interval=10s timeout=20s role=Unpromoted
+24
View File
@@ -0,0 +1,24 @@
Cluster name: postgres-ra-test
Cluster Summary:
* Stack: corosync (Pacemaker is running)
* Current DC: DAVID-DV6 (version 3.0.2-1.fc43-61983e8) - partition with quorum
* Last updated: Sat Sep 12 01:12:28 2026 on DAVID-ELITEDESK
* Last change: Sat Sep 12 00:02:03 2026 by root via cibadmin on DAVID-ELITEDESK
* 2 nodes configured
* 2 resource instances configured
*** Resource management is DISABLED ***
The cluster will not attempt to start, stop or recover services
Node List:
* Online: [ DAVID-DV6 DAVID-ELITEDESK ]
Full List of Resources:
* Clone Set: pg-ha-clone [pg-ha] (promotable, maintenance):
* pg-ha (ocf:loxthelion:managed-container): Promoted DAVID-DV6 (maintenance)
* pg-ha (ocf:loxthelion:managed-container): Unpromoted DAVID-ELITEDESK (maintenance)
Daemon Status:
corosync: active/disabled
pacemaker: active/disabled
pcsd: active/enabled