Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add checks to ensure existing PVC matches PVC to restore
Currently, the check for existing PVC, if found during PVC restore, checks to see if PVC exists and is restored by Ramen. This is insufficient in the case of a StatefulSet where the PVC maybe left behind (similar to the PV) post a failover or a relocate and on restore of the PVC if the older PVC is found, it may not be restored by Ramen. The checks for existing PVCs is hence expanded to ensure: - PVC is not deleted - PVC is bound - PVC is bound to the same PV volume name we would have restored The above ensures that we would have restored the same PVC and it would have been bound to the PV as desired. Also, the check to ensure that if the PVC exists it is restored by Ramen is dropped, as that may fail in cases as mentioned above. Signed-off-by: Shyamsundar Ranganathan <[email protected]> (cherry picked from commit 1805b30)
- Loading branch information