Error: "The IP address of that host is already being metered for vCenter" while registering VMware products in Usage Meter
search cancel

Error: "The IP address of that host is already being metered for vCenter" while registering VMware products in Usage Meter

book

Article ID: 409019

calendar_today

Updated On:

Products

VMware Usage Meter

Issue/Introduction

  • Unable to register VMware products (like ARIA Ops, NSX-T etc) in VUSM 9.
    Error: the IP address of that host is already being metered for vCenter
  • We get the below error from /opt/vmware/cloudusagemetering/platform/log/dss_main.log :
    INFO --- [https-https-####-###-##] c.vmware.um.dss.handler.ProductService   : Existing product with same endpoint found :ProductEndpointInfo{host=###-##-##.com', port=443}
    ERROR --- [https-####-###-##] c.v.u.dss.controllers.ProductController  : Product endpoint conflict
    com.vmware.um.dss.handler.ProductService$EndpointConflictException: Unable to add vrops=###-##-##.com:443, the IP address of that host is already being metered for vCenter.
    at com.vmware.um.dss.handler.ProductService.checkDuplicateProduct(ProductService.java:697)

Environment

Usage Meter: 9.0.1

 

Cause

This is a known issue in UM  9.0.1 

Resolution

This is resolved in VMware Cloud Foundation Usage Meter 9.0.1.100

Workaround to force a product creation:
    1. Login to UM via ssh and edit the file /opt/vmware/cloudusagemetering/platform/conf/products/nsxt.conf
          - Add the following element into the "productAttributes" array:
        {
              "attribute": "forceCreation",
              "type": "Boolean",
              "upload": false,
              "optional": true
        }
          - Add the following attribute into the "restApi->rest2productAttributesMapping" array:
        {
              "restApi": "forceCreation",
              "product": "forceCreation"
        }
          - save the changes
          - restart dss service by executing:
            * stop.sh dss
            * start.sh dss

    2. Get UM Access token
        curl --request POST \
          --url https://<UM_URL>/api/v2/auth \
          --header 'accept: application/json' \
          --header 'authorization: Basic <BASE64 UM_USER:UM_PASS>'

    3. Add product by adding forceCreation into the request body
        curl --request POST \
          --url 'https://<UM_URL>/api/v1/product' \
          --header 'accept: application/json' \
          --header 'authorization: Bearer <UM_ACCESS_TOKEN>' \
          --header 'content-type: application/json' \
          --data '{
          "productType": "NSX-T",
          "user": "<NSXT_USERNAME>",
          "password": "<NSXT_PASSWORD>",
          "host": "<NSXT_URL>",
          "port": <NSXT_PORT>,
          "forceCreation": true
           }'

    Step 1) have to be executed for each product config that you are using - e.g. nsxt.conf, vcenter.conf, vrops.conf, etc. 
    Step 3) should be executed for each product you want to create/add - e.g. productType vCenter, VROPS, NSX-T.