VCF 9.0 - Fail to add domain when using VDS specs with empty port group specs due to NullPointerException
search cancel

VCF 9.0 - Fail to add domain when using VDS specs with empty port group specs due to NullPointerException

book

Article ID: 405994

calendar_today

Updated On:

Products

VMware SDDC Manager

Issue/Introduction

All of the following symptoms need to be present: 

  • The "Add VI domain" workflow fails on step "Generate vSphere Internal Model for Workload Domain Input Data"
  • NFS datastore type is being used for the cluster 
  • In domain manager logs, the following null pointer exception can be observed:

  • YEARTDATETIME DEBUG [vcf_dm,687e3dec8f88095b4a21c74025caa60e,0ea5] [c.v.v.c.f.a.GenerateAddClusterInternalModelAndRecipeParamsAction,dm-exec-28]  Caught an exception:
    java.lang.NullPointerException: Cannot invoke "java.util.List.iterator()" because "portGroupSpecs" is null
        at com.vmware.vcf.clustermanager.fsm.actions.GenerateAddClusterInternalModelAndRecipeParamsAction.isNetworkTypePresentInDvsSpec(GenerateAddClusterInternalModelAndRecipeParamsAction.java:629)
        at com.vmware.vcf.clustermanager.fsm.actions.GenerateAddClusterInternalModelAndRecipeParamsAction.lambda$getDvsByNetworkType$15(GenerateAddClusterInternalModelAndRecipeParamsAction.java:622)
        at java.base/java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:178)

Environment

VCF 9.0

VCF Installer 9.0

Cause

The code is attempting to search for the NFS transport type port groups in the defined VDS list, but comes across a VDS with an empty list of port groups (which it does not expect) before it finds NFS traffic VDS. 

Resolution

  • If initiating workflow from UI:
    • Input the VDS with empty list of port groups last, so that it comes after the VDSes which contain the management and NFS transport type port groups
  • If initiating workflow from API:
    • In the list of VDS specs, ensure the VDS with empty list of port groups comes last, so that it comes after the VDSes which contain the management and NFS transport type port groups