zalando / spilo

Highly available elephant herd: HA PostgreSQL cluster using Docker
Apache License 2.0
1.52k stars 374 forks source link

'could not connect to Postgres database' on current master branch #923

Closed oursland closed 5 months ago

oursland commented 10 months ago

I am testing out the current master branch. After postgres-operator launches the database instances, they cannot be reached via the service, however the pods can be connected to directly with the appropriate kubectl port-forward.

I have cloned spilo and used the GitHub Action to build a release: https://github.com/oursland/spilo/pkgs/container/spilo-15/129897768?tag=v2023.09.20.0

This issue is not present in the Spilo 3.0-p1 release: ghcr.io/zalando/spilo-15:3.0-p1

Versions:

postgres-operator log message:

time="2023-09-22T17:53:57Z" level=warning msg="could not connect to Postgres database: dial tcp 10.43.255.26:5432: i/o timeout" cluster-name=default/postgres2 pkg=cluster worker=1 

Minimal example that exhibits the issue.

apiVersion: acid.zalan.do/v1
kind: postgresql
metadata:
  name: postgres2
  labels:
    team: acid
spec:
  dockerImage: ghcr.io/oursland/spilo-15:v2023.09.20.0
  teamId: acid
  numberOfInstances: 3
  postgresql:
    version: "15"
  volume:
    size: 1Gi
  resources:
    requests:
      cpu: 100m
      memory: 128Mi
    limits:
      cpu: 1000m
      memory: 1024Mi
sass1997 commented 9 months ago

Any news here I'm having the same behaviour after upgrading from 1.8.0 to 1.10.0?

hughcapet commented 5 months ago

I guess, should have been fixed by https://github.com/zalando/spilo/commit/06b53d29710cfb7eae483db6d2732e40e50fa435