This documentation is for a release that is no longer maintained
See documentation for the latest supported version 3 or the latest supported version 4.6.6. 卸载 MTC 并删除资源
您可以卸载 MTC,并删除其资源来清理集群。
注意
删除 velero
CRD 会从集群中移除 Velero。
先决条件
-
您必须以具有
cluster-admin
权限的用户身份登录。
流程
删除所有集群中的
MigrationController
自定义资源 (CR):oc delete migrationcontroller <migration_controller>
$ oc delete migrationcontroller <migration_controller>
Copy to Clipboard Copied! - 使用 Operator Lifecycle Manager 在 OpenShift Container Platform 4 上卸载 MTC Operator。
运行以下命令,删除所有集群中的集群范围资源:
migration
自定义资源定义 (CRDs):oc delete $(oc get crds -o name | grep 'migration.openshift.io')
$ oc delete $(oc get crds -o name | grep 'migration.openshift.io')
Copy to Clipboard Copied! Velero
CRD:oc delete $(oc get crds -o name | grep 'velero')
$ oc delete $(oc get crds -o name | grep 'velero')
Copy to Clipboard Copied! migration
集群角色:oc delete $(oc get clusterroles -o name | grep 'migration.openshift.io')
$ oc delete $(oc get clusterroles -o name | grep 'migration.openshift.io')
Copy to Clipboard Copied! migration-operator
集群角色:oc delete clusterrole migration-operator
$ oc delete clusterrole migration-operator
Copy to Clipboard Copied! velero
集群角色:oc delete $(oc get clusterroles -o name | grep 'velero')
$ oc delete $(oc get clusterroles -o name | grep 'velero')
Copy to Clipboard Copied! migration
集群角色绑定:oc delete $(oc get clusterrolebindings -o name | grep 'migration.openshift.io')
$ oc delete $(oc get clusterrolebindings -o name | grep 'migration.openshift.io')
Copy to Clipboard Copied! migration-operator
集群角色绑定:oc delete clusterrolebindings migration-operator
$ oc delete clusterrolebindings migration-operator
Copy to Clipboard Copied! velero
集群角色绑定:oc delete $(oc get clusterrolebindings -o name | grep 'velero')
$ oc delete $(oc get clusterrolebindings -o name | grep 'velero')
Copy to Clipboard Copied!