> For the complete documentation index, see [llms.txt](https://docs.cennso.com/components/fpp/latest/llms.txt) (all documentation: [llms.txt](https://docs.cennso.com/llms.txt)). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cennso.com/components/fpp/latest/troubleshooting/verification.md).

# Deployment verification

To verify if FPP deployment works correctly, you can perform the following actions:

1. [Check FPP pod](#check-fpp-pod)
1. [Verify uplink interfaces](#verify-uplink-interfaces)
1. [Check VPP logs](#check-vpp-logs)
1. [Check VPP errors](#check-vpp-errors)
1. [Deploy example workload](#iperf-deployment-example)

## Check FPP pod

FPP DaemonSet includes liveness and readiness probes. It checks for the uplink interface's existence and if the VPP process is alive. If one of those is not working, the FPP pod is restarted.

To check whether the FPP pod has an IP assigned, check the pod annotations. For example:

```yaml
apiVersion: v1
kind: Pod
metadata:
  annotations:
    ...
    k8s.v1.cni.cncf.io/network-status: |-
      [
      ...
      {
          "name": "fpp/uplink0",
          "interface": "net1",
          "ips": [
              "10.35.38.2"
          ],
          "dns": {},
          "device-info": {
              "type": "pci",
              "version": "1.0.0",
              "pci": {
                  "pci-address": "0000:18:03.7"
              }
          }
      },{
          "name": "fpp/uplink1",
          "interface": "net2",
          "dns": {},
          "device-info": {
              "type": "pci",
              "version": "1.0.0",
              "pci": {
                  "pci-address": "0000:18:0b.7"
              }
          }
      }]
    k8s.v1.cni.cncf.io/networks: fpp/uplink0,fpp/uplink1
```

In this example, the uplink IP is `10.35.38.2`. Network annotations also include the PCI address of NIC VFs (Virtual Functions)
assigned to the FPP pod. FPP requires an environment variable with PCI IDs, which SRIOV Operator provides:

```bash
export | grep PCI
```

Output example:

```bash
declare -x PCIDEVICE_OPENSHIFT_IO_UPLINK0_VFIO="0000:18:03.7"
declare -x PCIDEVICE_OPENSHIFT_IO_UPLINK1_VFIO="0000:18:0b.7"
```

If the uplink IP is not in pod annotations or there are no PCI IDs passed as environment variables, check `SRIOVNetwork` resources
assigned to FPP deployment or IPAM settings in your cluster.

## Verify uplink interfaces

To check if the uplink IP is assigned to the uplink VPP interface, run this command inside the FPP node pod:

```bash
vppctl show int address
```

Output example:

```bash
...
uplink-bond (up):
  L3 10.35.38.2/24 ip4 table-id 500 fib-idx 1
uplink0n0 (up):
uplink1n0 (up):
...
```

If there is no IP address assigned, there are some issues in pod network annotation or IPAM.
For further investigation, verify if there's [connectivity between FPP nodes](https://docs.cennso.com/components/fpp/latest/troubleshooting/connectivity.md#connectivity-between-nodes).

## Check VPP logs
After the FPP pod is spawned, you can find useful information in VPP logs.
To check VPP logs, run this command inside the FPP pod:

```bash
vppctl sh log
```

Output example:

```bash
...
2022/10/26 19:59:57:625 notice     dpdk           EAL init args: --in-memory --no-telemetry --file-prefix vpp -a 0000:18:03.7 -a 0000:18:0b.7
...
2022/10/26 19:59:59:059 notice     dpdk           EAL: Detected CPU lcores: 64
2022/10/26 19:59:59:059 notice     dpdk           EAL: Detected NUMA nodes: 2
2022/10/26 19:59:59:059 notice     dpdk           EAL: Detected static linkage of DPDK
2022/10/26 19:59:59:059 notice     dpdk           EAL: Selected IOVA mode 'VA'
2022/10/26 19:59:59:059 notice     dpdk           EAL: No available 1048576 kB hugepages reported
2022/10/26 19:59:59:059 notice     dpdk           EAL: No free 1048576 kB hugepages reported on node 0
2022/10/26 19:59:59:059 notice     dpdk           EAL: No free 1048576 kB hugepages reported on node 1
2022/10/26 19:59:59:059 notice     dpdk           EAL: No available 1048576 kB hugepages reported
2022/10/26 19:59:59:059 notice     dpdk           EAL: VFIO support initialized
2022/10/26 19:59:59:059 notice     dpdk           EAL: Using IOMMU type 1 (Type 1)
2022/10/26 19:59:59:059 notice     dpdk           EAL: Probe PCI driver: net_iavf (8086:154c) device: 0000:18:03.7 (socket 0)
2022/10/26 19:59:59:059 notice     dpdk           EAL: Probe PCI driver: net_iavf (8086:154c) device: 0000:18:0b.7 (socket 0)
...
2022/10/26 20:00:03:326 notice     dpdk           iavf_execute_vf_cmd(): Return failure -5 for cmd 11
2022/10/26 20:00:03:326 notice     dpdk           iavf_add_del_eth_addr(): fail to execute command OP_DEL_ETH_ADDR
2022/10/26 20:00:03:326 notice     dpdk           iavf_dev_set_default_mac_addr(): Fail to delete old MAC:0E:55:B6:74:D0:EB
2022/10/26 20:00:04:176 notice     dpdk           iavf_configure_queues(): RXDID[1] is not supported, request default RXDID[1] in Queue[0]
2022/10/26 20:00:04:176 notice     dpdk           iavf_configure_queues(): RXDID[1] is not supported, request default RXDID[1] in Queue[1]
2022/10/26 20:00:04:176 notice     dpdk           iavf_configure_queues(): RXDID[1] is not supported, request default RXDID[1] in Queue[2]
2022/10/26 20:00:04:176 notice     dpdk           iavf_configure_queues(): RXDID[1] is not supported, request default RXDID[1] in Queue[3]
...
2022/10/26 20:00:04:309 notice     dpdk           iavf_execute_vf_cmd(): Return failure -5 for cmd 11
2022/10/26 20:00:04:309 notice     dpdk           iavf_add_del_eth_addr(): fail to execute command OP_DEL_ETH_ADDR
2022/10/26 20:00:04:309 notice     dpdk           iavf_dev_set_default_mac_addr(): Fail to delete old MAC:56:30:19:47:3E:2F
2022/10/26 20:00:05:159 notice     dpdk           iavf_configure_queues(): RXDID[1] is not supported, request default RXDID[1] in Queue[0]
2022/10/26 20:00:05:159 notice     dpdk           iavf_configure_queues(): RXDID[1] is not supported, request default RXDID[1] in Queue[1]
2022/10/26 20:00:05:159 notice     dpdk           iavf_configure_queues(): RXDID[1] is not supported, request default RXDID[1] in Queue[2]
2022/10/26 20:00:05:159 notice     dpdk           iavf_configure_queues(): RXDID[1] is not supported, request default RXDID[1] in Queue[3]
...
2022/10/26 20:00:05:376 notice     ip/neighbor    add: uplink-bond, 10.35.38.3
2022/10/26 20:00:05:377 notice     ip/neighbor    add: uplink-bond, 10.35.38.1
```

The output presents typical information that you can see in VPP logs.

## Check VPP errors

FPP provides the following error metrics:

* `vpp_interface_errors` - multiple errors are reported, for example, if an interface is down or packet drops happen
  with memif or DPDK interface
* `vpp_interface_no_tx_slots` - shows issues with packet processing or system overload
* `vpp_arp_requests_sent` - if many ARP requests are sent, it may indicate a wrong cluster configuration in terms of IP reachability
* `vpp_arp_hw_addr_not_match_l2_frame` - arp-reply arrived on the interface, but it does not correspond to the local HW address
* `vpp_node_vectors{name="drop"}` - shows that packets are dropped on a specific VPP instance

## iPerf deployment example

Here is the example of the [iPerf deployment](https://docs.cennso.com/api/assets/components/fpp/latest/assets/example-config/fpp-example-iperf.yaml) that uses FPP networks.
You can deploy it on the cluster. The requirement to run the iPerf example is that FPP-enabled nodes
are labeled with `fpp-manager.cennso.com/vppswitch: ""`.

To verify if FPP works correctly:

1. Log into the `iperf3-client-0` pod and run `iperf3 -c 10.0.0.1`. The client pod should be able to connect to the iperf server.
1. If there is no connectivity between the pods, [follow this guide](https://docs.cennso.com/components/fpp/latest/troubleshooting/connectivity.md#connectivity-between-pods).

## Check BGP configuration

Follow the [BGP verification steps in the feature description](https://docs.cennso.com/components/fpp/latest/deployment-guides/bgp.md#verification).
