Skip to main content
NetApp Stage KB

Why host is showing 100% used space of empty postgres datastore mounted by Persistent Volume Claim (PVC)

Views:
Visibility:
Public
Votes:
0
Category:
astra_trident
Specialty:
SNAPX
Last Updated:

 

 

Applies to

  • Astra Trident
  • Kubernetes
  • SolidFire 
  • Postgres

Answer

Postgres writes regulary WAL (Write Ahead Logs). This WAL files are allocating 16MB space on the filesystem, but the file itself contains only zeros until something is written. Even if nothing is written and the file remains completely zeroed, additional files are created. As SolidFire is ignoring those zeros, the result is 100% filled file system and only 6% filed volume on SolidFire

Additional Information

SolidFire storage is using thin provisioning by default. Host or pod doesn't know it's thin, so they prented it's a full disk.The PVC claims 100% of the Persistent Volume (PV)

Example

# df -h | grep pvc-66d6dcb7-4b2c-4adb-90f6-604cc49d671a

/dev/mapper/36f47acc10000000034796a650000025a                   16G   15G     0 100% /var/lib/kubelet/pods/f0463b03-5fca-4f3a-a4f2-71d4ca38e16d/volumes/kubernetes.io~csi/pvc-66d6dcb7-4b2c-4adb-90f6-604cc49d671a/mount

while SF storage is showing only 6% used:

image

This case scenario is typical for postgres. The value of used space on a host might not be always 100%

 

NetApp provides no representations or warranties regarding the accuracy or reliability or serviceability of any information or recommendations provided in this publication or with respect to any results that may be obtained by the use of the information or observance of any recommendations provided herein. The information in this document is distributed AS IS and the use of this information or the implementation of any recommendations or techniques herein is a customer's responsibility and depends on the customer's ability to evaluate and integrate them into the customer's operational environment. This document and the information contained herein may be used solely in connection with the NetApp products discussed in this document.

 

  • Was this article helpful?