Archive for April, 2013

Nas4Free and support for Mellanox ConnectX 10GbE

Thursday, April 11th, 2013

I have been implementing Nas4Free recently, and found this system to be a very nice one. I might try to port its web interface to Linux, as it completes a set of requirements (regarding graphic interface) I do not find in Linux, and wish I could…

However, I have had to add a driver for ConnectX 10GbE interface, which, unfortunately, was not included.

This might show as a simple task, however, for a person unfamiliar with FreeBSD, it was a challenge.

I have followed the steps described in this build-your-own Nas4Free wiki guide, except a minor change:
I have edited the file /usr/local/nas4free/svn/build/kernel-config/NAS4FREE-amd64 (attached: NAS4FREE-amd64).

I did not build the system beyond compiling the kernel, as I needed only the kernel – I needed to implant the kernel into an embedded system. The procedure was as follow:

  • On the compilation server, run: cat /usr/obj/nas4free/usr/src/sys/NAS4FREE-amd64/kernel | gzip -n -9 > /tmp/kernel.gz
  • On the target system: note the device for the mount /cf
  • umount /cf (because it’s read-only)
  • mount the device noted before to /cf (now /cf is writable)
  • Copy from compilation server the file /tmp/kernel.gz to /cf/boot/kernel/ overwriting the existing file
  • umount /cf
  • Reboot

This is how to compile with extended support and to push it into an embedded Nas4Free system. Note, however, that the version of my Nas4Free was Newer versions might include the Mellanox drivers, and this operation will be obsolete.