You can configure Telegraf to monitor operating systems in physical servers.

Prerequisites

Procedure

  1. Create a refresh token from the following location in the Cloud Service portal:
    ( https://console.cloud.vmware.com/csp/gateway/portal/#/user/tokens/generate )

    User/Organization Settings >> My Account >> API Tokens >> Generate a New API Token

  2. Download Telegraf on the end point from cloud proxy.
    Invoke-RestMethod https://<cloud-proxy>/downloads/salt/telegraf.tar.gz -OutFile telegraf.zip
    Note: Use the relevant cloud proxy IP address for <cloud-proxy> in the preceding location specified.
  3. Create a certificate signing request by running the following command:
    $UUID=[guid]::NewGuid().guid
    openssl req -new -newkey rsa:2048 -nodes -keyout key.pem -out csr.pem -subj "/C=IN/ST=KA/L=BLR/O=VMWARE/OU=CMBU/CN=$UUID"
    
  4. Sign the certificate using the vRealize Operations Cloud Suite API.
    1. Use the refresh token (step 1) to get the access token. Run the following command:
      Invoke-RestMethod 'https://console.cloud.vmware.com/csp/gateway/am/api/auth/api-tokens/authorize' `
           -Method 'POST' `
           -Headers @{"Accept" = "application/json"; "Content-Type" = "application/x-www-form-urlencoded"} `
           -Body "refresh_token=${refresh_token}"
      
    2. Get the collector ID by running the following command:
      Invoke-RestMethod 'https://www.mgmt.cloud.vmware.com/vrops-cloud/suite-api/api/collectors?host=<cloud-proxy>' `
          -Headers @{'Accept' = 'application/json'; 'Authorization' = "CSPToken ${access_token}"}
      
    3. Get the signed certificate and CA as a ZIP file. Run the following command:
      Invoke-RestMethod 'https://www.mgmt.cloud.vmware.com/vrops-cloud/suite-api/api/applications/clientCertificate/<cloud-proxy-id>' `
           -Method 'POST' `
           -ContentType 'application/octet-stream' `
           -Headers @{'Authorization' = "CSPToken ${access_token}"} `
           -InFile csr.pem `
           -OutFile certificate-bundle.zip
      
      Note: Use the cloud proxy collector ID as the <cloud-proxy-id> in the preceding example.
  5. Extract the telegraf binary and the signed certificate-bundle. Update the telegraf configuration with the following settings:
    [[outputs.http]]
      url = "https://<cloud-proxy>/arc/default/metric"
      insecure_skip_verify = true
      tls_ca = "ca.cert.pem"
      tls_cert = "cert.pem"
      tls_key = "key.pem"
      data_format = "wavefront"
    
      [outputs.http.headers]
        uuid = "$(uuidgen)"
        hostname = "$(hostname)"
    
  6. Restart Telegraf and wait for 10 minutes to get the data.

What to do next

You can view the metrics by selecting the relevant object > Metrics Tab from the vRealize Operations Cloud user interface.