Mellanox ConnectX-3 w/FreeBSD 11.2 p6

KYP112

New Member

Reaction score: 1
Messages: 9

Hi Everyone,

I just setup PfSense 2.4.4 p2 with FreeBSD 11.2 Release p6 on an HP server node. Now I am looking to install the drivers for a dual 40gbe port Mellanox network card that I have in the slot.

I followed the tutorials online to install FreeBSD in a vm and compile the drivers. However I noticed mlxen module is no where to be found in any folder and when I go to compile.

I can compile mlx4, mlx4en, mlx5, and mlx5en but no mlxen. I have been checking online everywhere to see why as I am on the correct branch for 11.2 and did git clone in the vm so everything else worked just fine.

This card is new to me and first time going through this process before.

Any thoughts? or advice on where I can best find that module? I am searching through the forum to see if this was answered before unless I missed it.

Thank you!
 

Phishfry

Son of Beastie

Reaction score: 1,402
Messages: 4,131

No need to compile anything. Drivers are already built.
 
OP
OP
K

KYP112

New Member

Reaction score: 1
Messages: 9

Thank you for the reply and great to hear drivers are already built. This is what I followed initially:

So basically I just need to add to loader.conf the necessary lines for mlx4en?

Such as you mentioned in that thread link?
/etc/rc.conf
ifconfig_mlxen0="DHCP"

/boot/loader.conf
mlx4en_load="YES"

Also I was following online it is suggested to do a kldload mlxen to load the drivers and the problem is mlxen does not exist on my pfsense box. I did previously compile and transfer mlx4, mlx4en, mlx5, and mlx5en ko files before I posted this thread.

This is what I was following previously and noticed more people compiling drivers for FreeBSD 11+.
https://www.freebsd.org/cgi/man.cgi?query=mlx4en&sektion=&manpath=freebsd-release-ports (I see it says run kldload mlx4en)
 
OP
OP
K

KYP112

New Member

Reaction score: 1
Messages: 9

Okay when I try to do a kldload mlx4en this is the response I get in PfSense shell see attached. Version mismatch and unsupported file type. I am thinking when I compiled the drivers I transferred over to /boot/kernel/ they are from 11.2p4 FreeBSD and not p6 would that have anything to do with it?
 

Attachments

Phishfry

Son of Beastie

Reaction score: 1,402
Messages: 4,131

I have never copied over modules before. I did not think it was possible, but I see it in this post too.
Patch level should not matter unless the patch was related to the the module.

We have strayed over the line here. pfSense is not an appropriate support topic here. Don't want to be a jerk but it is the rule.
Without rules we have anarchy.
 

Phishfry

Son of Beastie

Reaction score: 1,402
Messages: 4,131

The answer lies here in the manual for module(9)
MODULE_DEPEND(foo, bar, 1, 3, 4);
So modules have dependencies. Now look at the messages you presented.
linuxkpi and mlx4 modules are also going to be needed by pfSense. They are dependencies.
You might need to run through it several times until you have copied over all depend modules.
linuxkpi might have its own set of dependencies.
 
OP
OP
K

KYP112

New Member

Reaction score: 1
Messages: 9

Thank you and sorry about that I was not sure how much I could mention about that software but will keep it out of here understood.

I see you mean run it through compiling the drivers or adding them on directly? Sorry still figuring out whether I should get it from the FreeBSD VM or do it directly. Now are they should be all located on the latest release 11.2 p6.
 

Phishfry

Son of Beastie

Reaction score: 1,402
Messages: 4,131

It looks like you can copy the modules over directly. I wouldn't worry about the patch level.
Copy those two ko's over and reboot, see if it compains about any more missing links.
 
OP
OP
K

KYP112

New Member

Reaction score: 1
Messages: 9

Okay I will check tomorrow morning back at the office. Thank you for the help. I will let you know the results.
 
OP
OP
K

KYP112

New Member

Reaction score: 1
Messages: 9

Okay some reason looking for linuxkpi to create a ko but unable to locate it as of yet. I am completely newbie to all this. Thought it would be in the modules folder but nothing there. I have it under boot/kernel. Ah ok let me try transferring again. I have attached my results after copying over new linuxkpi, mlx4, mlx4en ko files into boot/kernel/
 

Attachments

OP
OP
K

KYP112

New Member

Reaction score: 1
Messages: 9

Is there a better route than instead of compiling the drivers? If the modules are already with FreeBSD 11.2 I would think I could load them on the main FreeBSD machine itself.
 
OP
OP
K

KYP112

New Member

Reaction score: 1
Messages: 9

Progress added the linuxkpi ko again and have a different message this time.

mlx4en.ko: Unsupported file layout
 

Phishfry

Son of Beastie

Reaction score: 1,402
Messages: 4,131

Not that I know of. Since your using that other OS you might not use the /etc/rc.conf setting and just use the /boot/loader.conf part.
That starts the driver, then I would use the WebGUI to configure it.
Consider me out. You must use the other forum now.
 
Top