1

I'm using docker swarm and was hoping to use these containers https://github.com/bitnami/bitnami-docker-pgpool and https://github.com/bitnami/bitnami-docker-postgresql-repmgr.

For postgres, I'm going to configure 3 different services and repmgr would elect the master and go about it's business of ensuring that stream replication is setup for hot standby.

Now what I wanted to do was create one service with pgpool. I want this to be highly available though and I've been reading about that in it's documentation https://www.pgpool.net/docs/latest/en/html/example-cluster.html. Apparently it requires that only one node be 'active' and the others be in 'standby' and to coordinate among themselves using a watchdog service. This requires that they all be aware of each other and have unique configurations on each.

Since I never intend pgpool to handle the replication and failure elections of the database, do they really need to be cluster aware? Can't I just have multiple active pgpool instances in the cluster without using the watchdog service?

FatalCatharsis
  • 3,407
  • 5
  • 44
  • 74
  • Hey, I was implementing the same scenario and having similar doubt on how to run mulitple instance of bitnami pgpool container. If you have the answer, do shed me some light. I post the same https://stackoverflow.com/questions/65349270/multiple-bitnami-pgpool-ii-container – jlim Dec 17 '20 at 23:07
  • @jlim I never got a straight answer on this, but what I gathered was that the watchdog capability was only relevant when pgpool was responsible for the actual replication. If you have something else like repmgr handling that and pgpool is just being used for it's caching and load balancing capability, then you don't need to worry about it. I've been running my cluster with multiple pgpool instances and no watchdog configuration without issues. – FatalCatharsis Dec 22 '20 at 18:34
  • @FatalChatrsis, do you mind sharing your pgpool compose file configuration with me ? Is it similar to the one I've posted or you have some other additional variables – jlim Dec 22 '20 at 19:21
  • @Jilm - pretty much the same plus some extras for passwords and stuff. https://gist.github.com/FatalCatharsis/7eac7cd1b224822065481b2d6353b54f – FatalCatharsis Dec 22 '20 at 22:00
  • Brilliant, thank you very much. – jlim Dec 23 '20 at 00:04

0 Answers0