Skip to content

Restart postgrescluster and pgbouncer #121

Description

@Eric-zch

Hi There,

I can restart pods in a postgrescluster with command:
kubectl patch postgrescluster/pcluster1 --type merge --patch '{"spec":{"proxy":{"pgBouncer":{"metadata":{"annotations":{"restarted":"'"$(date)"'"}}}}}}'

I can restart pgbouncer pods in a postgrescluster command.
kubectl patch postgrescluster/pcluster1 --type merge --patch '{"spec":{"metadata":{"annotations":{"restarted":"'"$(date)"'"}}}}'

could you make pgo support the restart feature?

For example:
restart pods with: kubectl pgo restart pcluster1
restart pgbouncer pods with: kubectl pgo restart pgbouncer pcluster1

Thank you.

Activity

  1. benjaminjb commented on May 2, 2025

    @benjaminjb
    Collaborator

    Hi @Eric-zch, that makes sense to me, I'll put a ticket in our backlog for that.

    Just to type out some thoughts:

    I wonder if it makes sense to have a consistent format for the command, maybe something like

    • kubectl pgo restart <pod-type> <cluster-name>
    • kubectl pgo restart <cluster-name> <flag for pod type>?

    And I'll just leave this reference here for docs that describe this behavior: https://access.crunchydata.com/documentation/postgres-operator/latest/tutorials/cluster-management/administrative-tasks

  2. Eric-zch commented on May 15, 2025

    @Eric-zch
    Author

    Hi @benjaminjb
    It's great to have a consistent command. I look forward to seeing it in future PostgreSQL Operator Client releases. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions