OPNsense Forum

English Forums => Hardware and Performance => Topic started by: ak360 on April 07, 2021, 01:01:47 pm

Title: Getting Mellanox Connectx-4 Lx 25Gb NIC to work
Post by: ak360 on April 07, 2021, 01:01:47 pm
Hello Forum People,

I have searched the forum and found some similar posts but none seem to experience my issue.

I am trying to add a Mellanox Connectx-4 Lx 25Gb NIC to my OPNsense 21.1 build but the NIC is not being recognised. I have tried adding the tuneable to load mlx5en at boot and that works however my card is still not detected in GUI. The card works fine on this system with windows or ESXi.

I am very much a beginner with FreeBSD so if I need to provide any further info please let me know and I will do so ASAP.

Thank you in advance,

Alex
Title: Re: Getting Mellanox Connectx-4 Lx 25Gb NIC to work
Post by: mimugmail on April 07, 2021, 01:25:32 pm
dmesg | grep mlx via CLI
Title: Re: Getting Mellanox Connectx-4 Lx 25Gb NIC to work
Post by: ak360 on April 07, 2021, 01:44:35 pm
Hi, Thank you

root@harr-rout:~ # dmesg | grep mlx
mlx5en: Mellanox Ethernet driver 3.5.2 (September 2019)
Title: Re: Getting Mellanox Connectx-4 Lx 25Gb NIC to work
Post by: mimugmail on April 07, 2021, 05:38:13 pm
And "ifconfig"?
Title: Re: Getting Mellanox Connectx-4 Lx 25Gb NIC to work
Post by: ak360 on April 07, 2021, 06:32:26 pm
Thanks again :)

I have removed MAC addresses from below.

Code: [Select]
igb0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=802028<VLAN_MTU,JUMBO_MTU,WOL_MAGIC>
        ether
        inet6 igb0 prefixlen 64 scopeid 0x1
        media: Ethernet autoselect
        status: no carrier
        nd6 options=23<PERFORMNUD,ACCEPT_RTADV,AUTO_LINKLOCAL>
igb1: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=802028<VLAN_MTU,JUMBO_MTU,WOL_MAGIC>
        ether
        inet 192.168.1.1 netmask 0xffffff00 broadcast 192.168.1.255
        inet6 igb1 prefixlen 64 scopeid 0x2
        media: Ethernet autoselect (1000baseT <full-duplex>)
        status: active
        nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
enc0: flags=0<> metric 0 mtu 1536
        groups: enc
        nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
        options=680003<RXCSUM,TXCSUM,LINKSTATE,RXCSUM_IPV6,TXCSUM_IPV6>
        inet6 ::1 prefixlen 128
        inet6 fe80::1%lo0 prefixlen 64 scopeid 0x4
        inet 127.0.0.1 netmask 0xff000000
        groups: lo
        nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
pflog0: flags=100<PROMISC> metric 0 mtu 33160
        groups: pflog
pfsync0: flags=0<> metric 0 mtu 1500
        syncpeer: 0.0.0.0 maxupd: 128 defer: off
        groups: pfsync

Title: Re: Getting Mellanox Connectx-4 Lx 25Gb NIC to work
Post by: mimugmail on April 08, 2021, 05:33:16 am
Strange. I only tested 3 and 5 so I am a bit unsure.
What exactly did you add to loader.conf.local
Title: Re: Getting Mellanox Connectx-4 Lx 25Gb NIC to work
Post by: ak360 on April 08, 2021, 03:37:03 pm

In tunables I put mlx5en_load, value = YES

seems to be loading fine just not seeing the card. Is there a way to elevate this to a ticket?
Title: Re: Getting Mellanox Connectx-4 Lx 25Gb NIC to work
Post by: mimugmail on April 08, 2021, 03:41:27 pm
Can you put mlx5en_load=“YES“ in a file /boot/loader.conf.local and reboot

Title: Re: Getting Mellanox Connectx-4 Lx 25Gb NIC to work
Post by: Patrick M. Hausen on April 08, 2021, 03:45:01 pm
Or just use `kldstat` - if the driver is loaded, then the loader.conf configuration is not your problem.