diff --git a/pkg/operator/operators/klusterlet/controllers/klusterletcontroller/klusterlet_cleanup_controller.go b/pkg/operator/operators/klusterlet/controllers/klusterletcontroller/klusterlet_cleanup_controller.go index 4c85f1412..931bdb062 100644 --- a/pkg/operator/operators/klusterlet/controllers/klusterletcontroller/klusterlet_cleanup_controller.go +++ b/pkg/operator/operators/klusterlet/controllers/klusterletcontroller/klusterlet_cleanup_controller.go @@ -219,6 +219,10 @@ func (n *klusterletCleanupController) checkConnectivity(ctx context.Context, if err == nil { return true, nil } + if errors.IsNotFound(err) { + klog.Infof("AppliedManifestWork not found, klusterlet %s", klusterlet.Name) + return true, nil + } // if the managed cluster is destroyed, the returned err is TCP timeout or TCP no such host, // the k8s.io/apimachinery/pkg/api/errors.IsTimeout,IsServerTimeout can not match this error