Supervisor is stuck in a "Removing" state with the message "info: NSX Resource cleanup is in progress."
search cancel

Supervisor is stuck in a "Removing" state with the message "info: NSX Resource cleanup is in progress."

book

Article ID: 451706

calendar_today

Updated On:

Products

VMware vSphere Kubernetes Service

Issue/Introduction

  • When disabling the Supervisor from Workload Management > Supervisor, the status shows the Supervisor is deleted but hangs with the message: "NSX Resource cleanup is in progress."

  • Verifying the logs in the vCenter Server under /var/log/vmware/wcp/wcpsvc.log shows a failure to delete the NSX segment because it has a VM or VIF attached. You will see log entries similar to the following:


    ERROR: Cleanup failed! Please try again.
    ERROR: Failed to delete segment vm-domain-c#:12fd762a-f2d4-####-####-######-vif-default-network-0-vm-domain-c#:12fd762a-f2d4-####-####-#####-vif-default-network-0, error {
    "httpStatus"
    "error_code"
    "module_name" : "Policy"
    "error_message" : "The object path=[/infra/segments/vm-domain-c#:12fd762a-f2d4-####-####-#####-vif-default-network-0] cannot be deleted as it has 1 VMs or VIFs attached. Disconnect all VMs and VIFs before deleting a segment.'



Environment

VMware Cloud Foundation (VCF) 9.0.

Cause

The Supervisor deactivation process fails to delete the NSX segment because an active port remains in use on that segment. This is typically caused by a virtual machine (VM) or network adapter still connected to the segment, which prevents the NSX resource clean-up process from completing.

Note: It is not expected to see VMs on a system-created segment. If any are present, please validate their purpose before disconnecting the VM from the segment.

Resolution

  1. Note down the segment name from the wcpsvc.log file.

  2. Log in to the NSX Manager.

  3. Navigate to Networking > Segments and filter for the segment identified in the logs.

  4. Examine the segment configuration to identify any active ports connected to it.

  5. Trace the active port to the specific virtual machine or network adapter connected to the segment.

  6. Remove the network adapter from the affected VM or disconnect the VM from the segment to clear the port.

  7. Monitor the vSphere Client; the Supervisor deletion task should now proceed and complete successfully.