istio / istio.io

Source for the istio.io site
https://istio.io/
Apache License 2.0
762 stars 1.53k forks source link

operator remove: with multiple revision fails with Operator controller is not installed #9171

Open shamsher31 opened 3 years ago

shamsher31 commented 3 years ago

Ref: https://istio.io/latest/docs/setup/install/operator/#uninstall

If multiple revision of Istio is installed with the operator. During the previous revision cleanup using the following command.

kubectl delete istiooperators.install.istio.io -n istio-system example-istiocontrolplane

The operator remove command with revision is not able to find a controller for the operator and throws the following error.

istioctl operator remove --revision 1-8-1
Operator controller is not installed in istio-operator namespace (no Deployment detected).
Aborting, use --force to override.

Found this issue while debugging https://github.com/istio/istio/issues/31304

shamsher31 commented 3 years ago

cc: @morvencao

morvencao commented 3 years ago

If I recall correctly, the 1-8-1 operator deployment was deleted by the another istio operator. It was deleted during the pruning process after end-users delete the old IOP CR. I raised a PR to fix that, see: https://github.com/istio/istio/pull/30949

tanjunchen commented 3 years ago

@morvencao In this case, you can try to delete the new iop, and you find that the iop is deleted, but the istio cluster is not deleted. An error occurred during the synchronization phase of the istio operator. see API server conflict during finalizer removal, retrying. https://github.com/istio/istio/pull/30949 will fix it?

morvencao commented 3 years ago

In this case, you can try to delete the new iop, and you find that the iop is deleted, but the istio cluster is not deleted.

Haven't try this case, you delete new IOP to rollback?

tanjunchen commented 3 years ago

@morvencao
no, I just want to uninstall the istio cluster. you can try to do this.