A few options to move forward:
Option 1: Check the service and bring it back online
- Log in to the problematic node (in this case,
<Node2IP>
). - Check if the "AzStackHCI" or related logical network service is running:
Get-Service -Name *HciNetworkService*
- Restart the service if it's down:
Restart-Service -Name <ServiceName>
- Once the service is responsive, retry the deletion.
Option 2: Forcibly delete the Logical Network via WMI or database cleanup
This method should only be done if you're absolutely sure the Logical Network is orphaned, and you can't restore connectivity to the node.
- Use WMI to remove the resource:
Get-WmiObject -Namespace "root\wmi" -Class MSFT_NetworkLogicalNetwork | Where-Object { $_.Name -eq "<YourLogicalNetworkName>" } | Remove-WmiObject
- If WMI doesn't help, you may have to remove the reference manually from the AzStack HCI state database, but this is risky and not documented for general users. Microsoft support usually handles this.
Option 3: Restore or Reconnect the Logical Network
If you're open to restoring instead of deleting, and the backend service was just temporarily unreachable
- Restart the related services on all nodes:
Restart-Service -Name "AzStackHCI*" -Force
- Re-attempt a Get and Set operation on the logical network:
Get-AzStackHCILogicalNetwork -Name "<YourLogicalNetworkName>" | Set-AzStackHCILogicalNetwork -Tags @{ restored = "true" }