[HCX] Cannot enable MON, un-extend / re-extend network and/or redeploy the NE appliance. All actions fail with Error: org.codehaus.jettison.json.JSONObject$Null
search cancel

[HCX] Cannot enable MON, un-extend / re-extend network and/or redeploy the NE appliance. All actions fail with Error: org.codehaus.jettison.json.JSONObject$Null

book

Article ID: 374010

calendar_today

Updated On:

Products

VMware HCX

Issue/Introduction

Attempting to perform any of the below tasks fails with the Error: org.codehaus.jettison.json.JSONObject$Null

  • Enable/Disable MON
  • un-extend / re-extend the network
  • Deleting/Removing Network Extension appliance
2024-07-25 11:35:44.325 UTC [InterconnectService_SvcThread-4312, IX:########-####-####-####-5ff9ee3d885b, J:83bf01ff, , TxId: TxId: >########-####-####-####-32e238571d84] ERROR c.v.v.h.s.i.InterconnectRemoveApplianceJob- InterconnectRemoveApplianceJob failed in >state DISABLE_TRUNK_PORTS. Error: org.code
haus.jettison.json.JSONObject$Null cannot be cast to org.codehaus.jettison.json.JSONObject.
java.lang.ClassCastException: org.codehaus.jettison.json.JSONObject$Null cannot be cast to org.codehaus.jettison.json.JSONObject
at java.util.Iterator.forEachRemaining(Iterator.java:116)
at java.util.Spliterators$IteratorSpliterator.forEachRemaining(Spliterators.java:1801)
at java.util.stream.ReferencePipeline$Head.forEach(ReferencePipeline.java:647)
at >com.vmware.vchs.hybridity.service.interconnect.AbstractInterconnectJob.configurePortPropertiesForPortGroups(AbstractInterconnectJob>.java:2330)

 

Environment

HCX 4.x

Cause

The only known method to produce this behavior is to modify the HCX L2E Segment Config from NSX while the segment is stretched by HCX. This will cause the HCX DB to be out of sync with the segment logical-switch config. 

In this example, the extended network segment (Test-11-376..) was removed from cloud/destination NSX T1, and a Service Interface was added/attached to the HCX L2E stretched segment. This caused a duplicate segment to be created with new logical-switch uuid.

Modifying the HCX extended NSX Segment outside of HCX is an unsupported operation. Please refrain from making such changes as it can lead to unexpected results. 

 

Resolution

To recover from this condition, please perform the steps below.

  • Force unextend the affected network
  • Delete the HCX L2E segment from Cloud/Destination NSX 
    • If the NE was in an HA pair, you should unextend all networks stretched by the NE HA-pair
  • Delete the NE (force delete if necessary)
  • Create a new NE
  • Re-extend the network on new NE
    • If using NE-HA, re-create the HA pair before starting to re-extend networks

If the above steps do not resolve the issue, please open an SR with Broadcom support and reference this Article #.