<p>I'm having a pain point with Kubernetes and I hope someone can help me out. I'm trying to see the contents of a PVC (Persistent Volume Claim), but it seems that the only way to do so is to mount the PVC into a container and check what's inside.</p>
<p>As you can imagine, this is quite cumbersome and not very practical. I was wondering if there are any tools or solutions that could make this process easier?</p>
<p>I've searched around but haven't found anything yet. If anyone has any ideas or suggestions, please let me know! I'm eager to hear your thoughts and experiences.</p>
<p>Thank you in advance!</p>

mahdi
<p>Unfortunately, there is no built-in way to do this. To get around this, you would have to attach the disk to a container or VM and inspect its contents</p>
<p>You need to add the pvc to a pod and copy the files using kubectl cp or list the files using kubectl exec to check the contents of PVC.</p>
<p>A simpler way is to create an inspector POD to inspect the contents of PVC and clean up the pod easily as explained in this <a href="https://frank.sauerburger.io/2021/12/01/inspect-k8s-pvc.html" rel="nofollow noreferrer">blog</a> by Frank Sauerburger.</p>
