Skip to content

[Bug]: Context deadline exceeded when running "du" via the plugin #9164

@gabriele-wolfox

Description

@gabriele-wolfox

Is there an existing issue already for this bug?

  • I have searched for an existing issue, and could not find anything. I believe this is a new bug.

I have read the troubleshooting guide

  • I have read the troubleshooting guide and I think this is a new bug.

I am running a supported version of CloudNativePG

  • I have read the troubleshooting guide and I think this is a new bug.

Contact Details

No response

Version

1.27 (latest patch)

What version of Kubernetes are you using?

1.34

What is your Kubernetes environment?

Azure

How did you install the operator?

YAML manifest

What happened?

When running the kubectl plugin status on a cluster, we got

Name                     default/p-kccjvr09h6
System ID:               7493177368860737565
PostgreSQL Image:        edbclouddp.azurecr.io/enterprisedb/starlight:16.10.0-5-debian-ba@sha256:2fa8b86615a86e6eaef6de3664d27bfd060666b114a34edfa714d1ccafe19ce1
Primary instance:        p-kccjvr09h6-6
Primary promotion time:  2025-11-01 09:13:41 +0000 UTC (287h18m44s)
Status:                  Cluster in healthy state
Instances:               2
Ready instances:         2
Size:                    cmd: [du -sLh /var/lib/postgresql/data/pgdata]
error: context deadline exceeded
...

Running the command into the pod, manually

$ date
Thu Nov 13 09:59:09 AM UTC 2025
$ du -sLh /var/lib/postgresql/data/pgdata
date
1.4T	/var/lib/postgresql/data/pgdata
$ Thu Nov 13 09:59:34 AM UTC 2025

takes longer than the timeout we set to 10 seconds.

[cloudnative-pg/internal/cmd/plugin/status/status.go at main · cloudnative-pg/cloudnative-pg]
(https://github.com/cloudnative-pg/cloudnative-pg/blob/main/internal/cmd/plugin/status/status.go#L220)

I guess we should increase the timeout.

Cluster resource

Relevant log output

Code of Conduct

  • I agree to follow this project's Code of Conduct

Metadata

Metadata

Assignees

Labels

triagePending triage

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions