Skip to main content
All CollectionsGetting StartedData Sources Configuration
How to Enable IPFix on Nutanix 5.20LTS
How to Enable IPFix on Nutanix 5.20LTS
A
Written by Alex Patnick
Updated this week

Warning! This process is not supported by Nutanix and is not recommended for production environments. If you follow the instructions written in this document and something breaks, you may have to rebuild your cluster to get to a known working state, although, this is unlikely.

The following instructions have been created in a Nutanix cluster running 5.20.4 LTS with Prism Central 2022.4.

For 6.1 STS and later, these instructions do not apply and you will use a different API call.

Note: All IP addresses are examples and should be replaced

Step 1

Verify that the exporter is configured inside all the AHV hosts to point to the existing FSCVM. Perform the following from any of the CVMs in the Prism Element cluster.

nutanix@CVM$ hostssh cat /etc/ipfix_exporter.conf

============= 10.54.26.27 ============
[[Collector]]
host = "10.54.26.51"
transport = "udp"
port = "4739"

============= 10.54.26.28 ============

[[Collector]]

host = "10.54.26.51"
transport = "udp"
port = "4739"

============= 10.54.26.26 ============

[[Collector]]
host = "10.54.26.51"
transport = "udp"
port = "4739"

============= 10.54.26.25 ============

[[Collector]]
host = "10.54.26.51"
transport = "udp"
port = "4739"

Step 2

Disable IPFix from FSCVM. Log into the web page of the FSCVM using the configured credentials. Go to Settings > Network Log Configurations > Disable.

blobid0.png

Step 3

Verify that the IPFix Exporter config is not present on the AHV hosts anymore. Perform the following using SSH on any CVM in the Prism Element cluster.

nutanix@CVM$ hostssh cat /etc/ipfix_exporter.conf

============= 10.54.26.27 ============

ERROR:root:Got Non Zero Return code 1 while executing cmd 'cat /etc/ipfix_exporter.conf' on host 10.54.26.27
ERROR:root:stderr: cat: /etc/ipfix_exporter.conf: No such file or directory
ERROR:root:stdout:

============= 10.54.26.28 ============

ERROR:root:Got Non Zero Return code 1 while executing cmd 'cat /etc/ipfix_exporter.conf' on host 10.54.26.28
ERROR:root:stderr: cat: /etc/ipfix_exporter.conf: No such file or directory
ERROR:root:stdout:

============= 10.54.26.26 ============

ERROR:root:Got Non Zero Return code 1 while executing cmd 'cat /etc/ipfix_exporter.conf' on host 10.54.26.26
ERROR:root:stderr: cat: /etc/ipfix_exporter.conf: No such file or directory
ERROR:root:stdout:

============= 10.54.26.25 ============

ERROR:root:Got Non Zero Return code 1 while executing cmd 'cat /etc/ipfix_exporter.conf' on
host 10.54.26.25
ERROR:root:stderr: cat: /etc/ipfix_exporter.conf: No such file or directory

ERROR:root:stdout:

Step 4

Create the IPFix exporter using REST API. Use Postman or another REST API tool to make an API call to the Prism Central instance.

Authentication: Use a user with admin privileges and password.
Method: POST
URL: https://##{{pc}}:9440/api/nutanix/v3/ipfix_exporters
Body:

{
"spec": {
 "resources": {
    "collector_ip_address": "10.1.1.1",
    "collector_port": 4739,
    "collector_protocol": "UDP"
  }
},
"metadata": {
  "last_update_time": "2022-05-11T10:31:09.833817942Z",
  "kind": "ipfix_exporter",
  "spec_version": 0,
  "creation_time": "2022-05-11T10:31:09.833817786Z",
  "owner_reference": {
    "kind": "user",
    "name": "admin",
    "uuid": "00000000-0000-0000-0000-000000000000"
  },
  "name": " ipfix-exporter",
  "should_force_translate": true,
  "spec_hash": ""
},
"api_version": "3.1.0"
}

Exporter create status has the UUID. Copy and paste this UUID from the response, because it is needed to DELETE later on. There is no easy way to retrieve this UUID other than looking at this response during creation.

Step 5

Verify that the V3 API calls work to enable the collector by looking at the Prism Central tasks.

blobid1.png

Step 6

Verify the IPFix exporter now targets the correct export destination by logging into any of the CVMs on the connected PE clusters over SSH.

nutanix@CVM$ hostssh cat /etc/ipfix_exporter.conf

============= 10.54.26.27 ============
[[Collector]]
host = "10.54.25.196"
transport = "udp"
port = "4739"

============= 10.54.26.28 ============
[[Collector]]
host = "10.54.25.196"
transport = "udp"
port = "4739"

============= 10.54.26.26 ============
[[Collector]]
host = "10.54.25.196"
transport = "udp"
port = "4739"

============= 10.54.26.25 ============
[[Collector]]
host = "10.54.25.196"
transport = "udp"
port = "4739"

Step 7

Verify IPFix Packets are Generated from AHV. Nutanix has verified by capturing these packets on the specified collector destination with tcpdump.

blobid2.png

How To Delete IPFix

When you are completely done with the IPFix exporter, you can delete the IPFix exporter using the UUID captured earlier in the create phase.

Authentication: Use the Prism Central “admin” account.

Method: DELETE

URL: https://##{{pc}}:9440/api/nutanix/v3/ipfix_exporters/##{{UUID}}

Body:

{
  "kind" : "ipfix_exporter"
}
Did this answer your question?