Node Interface Metrics Exporter Application

About this task

The Node Interface Metrics Exporter application is designed to fetch and display node statistics in a Kubernetes environment. It deploys an Interface Metrics Exporter DaemonSet on all nodes with the starlingx.io/interface-metrics=true node label. It uses the Netlink library to gather data directly from the kernel, offering real-time insights into node performance.

Node Interface Metrics Exporter provides the following details in the Open Metrics API format using REST APIs.

  1. Physical Function Interface Device information and Statistics.

    1. Device information contains device name, hardware address, broadcast, duplex, ifalias, operation state and pci-address.

    2. Statistics contains.

      • RX/TX packets, RX/TX bytes, multicast, RX/TX errors, RX/TX dropped, RX/TX compressed.

      • RX detailed errors (length, over, crc, frame, missed, fifo).

      • TX detailed errors (aborted, carrier, heartbeat, window, fifo).

  2. Virtual Function Interface Device information, Statistics and POD information.

    1. Device information contains device name, Virtual Function id, pci-adddress, hardware address, vlan, spoofcheck, trust.

    2. Statistics contains RX/TX packets, RX/TX bytes, RX/TX dropped, TX rate, TX rate max, TX rate min.

    3. POD information contains namespace, POD name, container name, resource name, device name, Virtual Function id, hardware address.

Install Node Interface Metrics Exporter Application

Follow the steps below to install the Node Interface Metrics Exporter application.

  1. Locate the application tarball in the /usr/local/share/applications/helm directory.

    For example:

    /usr/local/share/applications/helm/node-interface-metrics-exporter-<version>.tgz
    
  2. Upload the application using the following command, replacing <version> with the latest version number.

    ~(keystone_admin)]$ system application-upload /usr/local/share/applications/helm node-interface-metrics-exporter-<version>.tgz
    
  3. Verify that the application has been uploaded successfully.

    ~(keystone_admin)]$ system application-list
    
  4. Apply the application using the following command.

    ~(keystone_admin)]$ system application-apply node-interface-metrics-exporter
    

    The application should be in applied state.

  5. Monitor the status of the application using one of the following commands.

    ~(keystone_admin)]$ watch -n 5 system application-list
    

    OR

    ~(keystone_admin)]$ watch kubectl get pods -n node-interface-metrics-exporter
    

Uninstall Node Interface Metrics Exporter Application

Follow the steps below to uninstall the Node Interface Metrics Exporter application.

  1. Remove the application using the following command:

    ~(keystone_admin)]$ system application-remove node-interface-metrics-exporter
    
  2. Delete application using the following command:

    ~(keystone_admin)]$ system application-delete node-interface-metrics-exporter
    

Once uninstallation is complete, all related resources and configurations will be removed from the system.

Node Interface Metrics Exporter API

Note

The following APIs are expected to be accessed only from applications running internal to the cluster and should not be exported.

Node Interface Metrics Exporter API section contains the API details