VMware Networking Community
seangadson
Contributor
Contributor
Jump to solution

NSX-T Deploy Cluster Node

Hey I am getting the error below when I try to Deploy and register a cluster node VM using vRO?  Below is my rest request Detail:

API Post Request:

API Post Request URL: /api/v1/cluster/nodes/deployments

{

"deployment_requests" : [{

"user_settings" : {

"cli_password" : "<password>*",

"root_password" : "<password>"

},

"roles" : ["MANAGER"],

"deployment_config" : {

"placement_type" : "VsphereClusterNodeVMDeploymentConfig",

"vc_id" : "vCenterID",

"management_network_id" : "network-102",

"hostname" : "ny-nsxm",

"default_gateway_addresses" : ["10.4.4.1"],

"compute_id" : "domain-c81",

"storage_id" : "datastore-86",

"management_port_subnets" : {

"ip_addresses" : ["10.4.4.51"],

"prefix_length" : 22

},

"dns_servers" : ["10.0.0.2"]

},

"form_factor" : "SMALL"

}

]

}

And the response I recieve is below:

Request failed, incorrect response code received: '400' expected one of: '201'

{

  "httpStatus" : "BAD_REQUEST",

  "error_code" : 208,

  "module_name" : "common-services",

  "error_message" : "Can not construct instance of com.vmware.nsxapi.logicalrouterports.dto.IPSubnetDto[] for property deployment_requests.null.deployment_config.management_port_subnets"

}

Tags (2)
Reply
0 Kudos
1 Solution

Accepted Solutions
daphnissov
Immortal
Immortal
Jump to solution

Without trying this myself, I can only compare the body of yours to the reference provided in the documentation. I see one possible issue in the deployment_requests.deployment_config.manage_port_subnets object. Your body has a single object whereas the 2.5 documentation has an array of objects. See below for a truncated sample.

{

  "deployment_requests": [

    {

      "roles": ["CONTROLLER", "MANAGER"],

      "form_factor": "MEDIUM",

      "user_settings": {

        "cli_password": "CLIp4$$w4rd",

        "root_password": "ROOTp4$$w4rd"

      },

      "deployment_config": {

        "placement_type": "VsphereClusterNodeVMDeploymentConfig",

        "vc_id": "69874c95-51ed-4775-bba8-e0d13bdb4fed",

        "management_network_id": "network-13",

        "hostname": "node-0",

        "compute_id": "domain-s9",

        "storage_id": "datastore-12",

        "default_gateway_addresses": ["10.33.79.253"],

        "management_port_subnets": [

          {

            "ip_addresses": ["10.33.79.64"],

            "prefix_length": 22

          }

        ],

        "dns_servers": ["10.33.38.2"]

      }

    }

  ]

}

View solution in original post

Reply
0 Kudos
5 Replies
daphnissov
Immortal
Immortal
Jump to solution

Care to provide more details?

Reply
0 Kudos
seangadson
Contributor
Contributor
Jump to solution

I updated with more details

Reply
0 Kudos
daphnissov
Immortal
Immortal
Jump to solution

You say you're doing this through vRO? How? With what plug-in?

Reply
0 Kudos
seangadson
Contributor
Contributor
Jump to solution

Yea I am I am just using the NSX-T 2.5 Rest API not the actual NSX-T plugin

Reply
0 Kudos
daphnissov
Immortal
Immortal
Jump to solution

Without trying this myself, I can only compare the body of yours to the reference provided in the documentation. I see one possible issue in the deployment_requests.deployment_config.manage_port_subnets object. Your body has a single object whereas the 2.5 documentation has an array of objects. See below for a truncated sample.

{

  "deployment_requests": [

    {

      "roles": ["CONTROLLER", "MANAGER"],

      "form_factor": "MEDIUM",

      "user_settings": {

        "cli_password": "CLIp4$$w4rd",

        "root_password": "ROOTp4$$w4rd"

      },

      "deployment_config": {

        "placement_type": "VsphereClusterNodeVMDeploymentConfig",

        "vc_id": "69874c95-51ed-4775-bba8-e0d13bdb4fed",

        "management_network_id": "network-13",

        "hostname": "node-0",

        "compute_id": "domain-s9",

        "storage_id": "datastore-12",

        "default_gateway_addresses": ["10.33.79.253"],

        "management_port_subnets": [

          {

            "ip_addresses": ["10.33.79.64"],

            "prefix_length": 22

          }

        ],

        "dns_servers": ["10.33.38.2"]

      }

    }

  ]

}

Reply
0 Kudos