Question & Answer
Question
How to delete a PVC that remains in "Terminating" state after a failed attempt of apic upgrade from 2018 to v10?
Cause
Even after a force deletion of the pvc, it remains in "Terminating" state:
"kubectl delete pvc pv-claim-apiconnect-v10-upgrade --force --grace-period=0 -n default"
Persistentvolumeclaim "pv-claim-apiconnect-v10-upgrade" force deleted
PVC is not deleting due to the finalizers, which are blocking the deletion. You can read more about it here:
Answer
To resolve this issue, you can update the pvc and clear the finalizers:
kubectl patch pvc {PVC_NAME} -p '{"metadata":{"finalizers":null}}'
This command unsets the finalizers allowing the pvc to be deleted.
After deleting the pvc, continue to run the cleanup script and restart the upgrade process:
python3 dr-upgrade-cleanup.py
python3 dr-upgrade-extract.py
[{"Type":"MASTER","Line of Business":{"code":"LOB45","label":"Automation"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Product":{"code":"SSMNED","label":"IBM API Connect"},"ARM Category":[{"code":"a8m50000000CeCAAA0","label":"API Connect->Management and Monitoring (MM)->Upgrade\/Downgrade"}],"ARM Case Number":"TS006541086","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"10.0.0;2018.4.1.0"}]
Was this topic helpful?
Document Information
Modified date:
06 October 2021
UID
ibm16496819