Application will only function with 2 ports, num_of_ports=0

ubuntu@localhost:~$ sudo /opt/mellanox/doca/examples/url_filter/bin/doca_url_filter -a 0000:03:00.0,class=regex -a auxiliary:mlx5_core.sf.4,sft_en=1 -a auxiliary:mlx5_core.sf.5,sft_en=1
EAL: Detected 8 lcore(s)
EAL: Detected 1 NUMA nodes
EAL: Detected shared linkage of DPDK
EAL: Multi-process socket /var/run/dpdk/rte/mp_socket
EAL: Selected IOVA mode 'VA'
EAL: No available hugepages reported in hugepages-32768kB
EAL: No available hugepages reported in hugepages-64kB
EAL: No available hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: VFIO support initialized
EAL:   Device is not NUMA-aware, defaulting socket to 0
EAL: Probe PCI driver: mlx5_pci (15b3:a2d6) device: 0000:03:00.0 (socket 0)
mlx5_common: Verbs device not found: mlx5_core.sf.4
mlx5_common: Failed to initialize device context.
auxiliary_probe(): Requested device mlx5_core.sf.4 cannot be used

mlx5_common: Verbs device not found: mlx5_core.sf.5
mlx5_common: Failed to initialize device context.
auxiliary_probe(): Requested device mlx5_core.sf.5 cannot be used

EAL: Bus (auxiliary) probe failed.
EAL: No legacy callbacks, legacy socket not created
[12:17:52:933463][DOCA][E][FOFLD]: Application will only function with 2 ports, num_of_ports=0

ubuntu@localhost:~$ /opt/mellanox/iproute2/sbin/mlxdevm port show
pci/0000:03:00.0/229408: type eth netdev en3f0pf0sf0 flavour pcisf controller 0 pfnum 0 sfnum 0
  function:
    hw_addr 02:34:2a:1f:10:f4 state active opstate attached roce true max_uc_macs 128 trust off
pci/0000:03:00.0/229409: type eth netdev en3f0pf0sf4 flavour pcisf controller 0 pfnum 0 sfnum 4
  function:
    hw_addr 02:25:f2:8d:a2:4c state active opstate detached roce true max_uc_macs 128 trust on
pci/0000:03:00.0/229410: type eth netdev en3f0pf0sf5 flavour pcisf controller 0 pfnum 0 sfnum 5
  function:
    hw_addr 02:25:f2:8d:a2:5c state active opstate detached roce true max_uc_macs 128 trust on
pci/0000:03:00.1/294944: type eth netdev en3f1pf1sf0 flavour pcisf controller 0 pfnum 1 sfnum 0
  function:
    hw_addr 02:b9:a2:3c:63:34 state active opstate attached roce true max_uc_macs 128 trust off

some advice?

Did you perform the step where you unbind from the sf config driver and bind to the mlx5_core.sf driver?

ex)

echo mlx5_core.sf.4  > /sys/bus/auxiliary/drivers/mlx5_core.sf_cfg/unbind
echo mlx5_core.sf.4  > /sys/bus/auxiliary/drivers/mlx5_core.sf/bind

Also, you’ll need en3f0pf0sf4 to be trusted. en3f0pf0sf5 is already trusted.

I hadn’t done the “unbind” and “bind” operations and I forgot to set “trust” en3f0pf0sf4.
Thank you.

ubuntu@localhost:~$ sudo /opt/mellanox/doca/examples/url_filter/bin/doca_url_filter -a 0000:03:00.0,class=regex -a auxiliary:mlx5_core.sf.4,sft_en=1 -a auxiliary:mlx5_core.sf.5,sft_en=1
EAL: Detected 8 lcore(s)
EAL: Detected 1 NUMA nodes
EAL: Detected shared linkage of DPDK
EAL: Multi-process socket /var/run/dpdk/rte/mp_socket
EAL: Selected IOVA mode 'VA'
EAL: No available hugepages reported in hugepages-32768kB
EAL: No available hugepages reported in hugepages-64kB
EAL: No available hugepages reported in hugepages-1048576kB
EAL: Probing VFIO support...
EAL: VFIO support initialized
EAL:   Device is not NUMA-aware, defaulting socket to 0
EAL: Probe PCI driver: mlx5_pci (15b3:a2d6) device: 0000:03:00.0 (socket 0)
EAL: No legacy callbacks, legacy socket not created
Temporary WARN - Destination table level lower than Source
[22:25:24:266581][DOCA][I][DWRKR]: 7 cores are used as DPI workers
URL FILTER>> 

is it working correctly now?

Yes it looks like it’s started up. The URL filter application is interactive like this. The docs show you how to create, compile and apply rules.

I got this error “bash: echo: write error: No such device”.