Menu

1 / 5

Kubernetes CronJob pg_dump backup: does the dump end up on the same node as the database?

DEV Community: kubernetes·KYUNGHWAN KIM·3 days ago
#6i6JGlpr
#devtokubernetes#devto#dev#backup#server
Reading 0:00
15s threshold

Every backup Job completed. Five of the seven dumps were on the same disk as the databases they copy.

If your Kubernetes CronJob pg_dump backup writes to a PVC of the local-path StorageClass (the k3s default) and kubectl get jobs -A shows every backup Job as Complete 1/1 , that output does not tell you which node's disk the dump is on. On our cluster all seven backup Jobs completed on 2026-11-11, but five of the dumps were on the same single disk as the databases they copy, and every k3s etcd snapshot and the server token needed to restore them were on that disk too. A local-path volume is created on the node where the first pod that uses it is scheduled, and in five of our seven backup CronJobs nothing placed that pod on a node other than the database's. To see yours, list each PV with its node (check 1 below): if a backup claim and the database's data claim show the same NODE, the dump is on the database's node, and on the same disk if that node has only one.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.