Billing report guide

To obtain resource throughput usage data and generate your VNFM billing report (otherwise referred to in the EULA as, utility billing report), run the Generate Report workflow for the base deployment only, using one of the following methods:

This workflow merges output from all service layers to calculate the usage data for your specific BIG-IQ registration key every 180 days (default setting). However, you can also run a complete historical report. After running the billing report, send F5 the report in an email.

Prerequisite for running reports

Before executing the Generate Report workflow in your VNFM, you must start and run your BIG-IQ instance.

CAUTION: Generate utility reports on your VNF Manager only. Never manually generate utility reports on your BIG-IQ machines.

Report using a VNF Manager workflow

  1. In the F5 VNF Manager, click the Deployment blade.

  2. In the base deployment row (the deployment for the actual Gi-LAN or Gi-Firewall solution blueprint defined using the inputs file), expand menuIcon_report, and select the Generate Report workflow from the list.

  3. At the Execute workflow generate_report popup menu, leave the false default value in the full_historical_report text box, and then click Execute. A report will generate for the last 180 days of utility use. If you want to run a complete historical report, change this value to true.

  4. Once you generate the report, click the deployment in the list to open it, and then scroll down the page to the Deployment Outputs pane.

  5. In the Value column, double-click in generated_report cell to select the code text, right-click the selected text, choose Copy, paste the content into an email, and then send it to F5 Networks using the vesubscriptions@f5.com email address (listed in your EULA). A link to your EULA is located on the F5 VNF Manager download site on Centercode.

    _images/report_deployment_data.png

The frequency of sending generated reports to F5 is based on your EULA agreement/contract with F5 Networks. To find your agreement details, point your browser to the F5 VNF Manager download login site on Centercode, and then click the EULA link.

Report using the REST API

  1. Use the following code sample to generate and retrieve VNFM billing report using the REST API:

    import requests
    from requests.auth import HTTPBasicAuth
    import time
           VNFM_IP= "10.190.55.79"
           VNFM_USERNAME = "admin"
           VNFM_PASSWORD = "admin"
           VNFM_TENANT = "default_tenant"
           VNFM_BASE_DEPLOYMENT_ID = "example_deployment"
           # This should be switched to True in a production environment
           VERIFY_VNFM_CERT = False
           def start_generate_report():
               url = 'https://{}/api/v3.1/executions'.format(VNFM_IP)
               headers = {
                   'Content-Type': 'application/json',
                   'Tenant': VNFM_TENANT,
               }
               querystring = {'_include': 'id'}
               payload ={
                   'deployment_id': VNFM_BASE_DEPLOYMENT_ID,
                   'workflow_id': 'generate_report',
               }
               response = requests.post(
                   url,
                   auth=HTTPBasicAuth(VNFM_USERNAME, VNFM_PASSWORD),
                   headers=headers,
                   params=querystring,
                   json=payload,
                   verify=VERIFY_VNFM_CERT,
               )
               return response.json()["id"]
           def wait_for_successful_report_generation(id):
               number_of_retries = 10
               interval_between_retries = 2  # seconds
               url = 'https://{}/api/v3.1/executions/{}'.format(VNFM_IP, id)
               headers = {'Tenant': VNFM_TENANT}
               querystring = {'_include': 'status,error'}
               for i in xrange(number_of_retries):
                   response = requests.get(
                       url,
                       auth=HTTPBasicAuth(VNFM_USERNAME, VNFM_PASSWORD),
                       headers=headers,
                       params=querystring,
                       verify=VERIFY_VNFM_CERT,
                   )
                   response_json = response.json()
                   if response_json["status"] == "terminated":
                       if response_json["error"] != "":
                           print "generate_report workflow failed"
                       return True
                   time.sleep(interval_between_retries)
               return False
           def retrieve_report():
               url = 'https://{}/api/v3.1/node-instances'.format(VNFM_IP)
               headers = {'Tenant': VNFM_TENANT}
               querystring = {'_include': 'id,deployment_id,node_id,runtime_properties'}
               response = requests.get(
                   url,
                   auth=HTTPBasicAuth(VNFM_USERNAME, VNFM_PASSWORD),
                   headers=headers,
                   params=querystring,
                   verify=VERIFY_VNFM_CERT,
               )
               for item in response.json()["items"]:
                   if item["deployment_id"] == VNFM_BASE_DEPLOYMENT_ID and \
                       item["node_id"] == "master_information_collector":
                           return item["runtime_properties"]["jsonReport"]
           id = start_generate_report()
           if wait_for_successful_report_generation(id):
               generated_report = retrieve_report()
               with open("report.json", "w") as report_file:
                   report_file.write(generated_report)
    
  2. Copy and paste the report data into an email and send it to vesubscriptions@f5.com.

What’s Next?

REST API