<p>I wanted to know what's the difference of the <code>reclaimPolicy</code> in <code>StorageClass</code> vs. <code>PersistentVolume</code>.</p>
<p>Currently we created multiple <code>PersistentVolume</code> with a <code>StorageClass</code> that has a <code>reclaimPolicy</code> of <code>Delete</code>, however we changed the <code>PersistentVolume</code>'s <code>reclaimPolicy</code> manually via <code>kubectl patch pv PV_NAME -p '{&quot;spec&quot;:{&quot;persistentVolumeReclaimPolicy&quot;:&quot;Retain&quot;}}'</code> to have a <code>Retain</code> value.</p>
<p>what will happen now if I try to delete the <code>StorageClass</code> or even the cluster or accidentily remove <code>pvc</code>' s does the value of the <code>StorageClass</code> has any effect on the <code>pv</code> even after creating?</p>

<blockquote>
<p>I wanted to know what's the difference of the reclaimPolicy in StorageClass vs. PersistentVolume.</p>
</blockquote>
<p>They mean the same thing, the difference is that the one in <code>StorageClass</code> is used for <a href="https://kubernetes.io/docs/concepts/storage/dynamic-provisioning/" rel="noreferrer">dynamic provisioning of volumes</a>, for manually created persistent volumes they use the <code>reclaimPolicy</code> they were assigned during creation.</p>
<blockquote>
<p>what will happen now if I try to delete the StorageClass or even the cluster or accidentily remove pvc' s does the value of the StorageClass has any effect on the pv even after creating?</p>
</blockquote>
<p>I don't think anything will happen if you delete <code>StorageClass</code>, no pv or pvc should be deleted. If you delete a PVC then the <code>reclaimPolicy</code> of the <code>PersistentVolume</code> will be used.</p>
