USB Sharing on Linux NoMachine servers with Linux NoMachine Clients

I realized that, even on Ver. 6.3.6 of NoMachine , USB sharing didn’t work out of the box (that is,  in typical, straight forward installations).

To make USB sharing work (i.e. the USB stick you plug in to your client, appears as a USB device on the server) you need to compile nxusb.ko manually on the server (probably on the client as well) and restart the server and re-connect.

The manual compilation is done as follows:

Note: A more detailed document is at https://www.nomachine.com/AR11O00946

Make sure that Linux kernel headers are installed. If not, install them.

dpkg -l | grep linux-headers-$(uname -r)


Make sure that packages bintuils and gcc are installed. If not, install them.

Switch to root and compile nxusb kernel object.

sudo su –
cd /usr/NX/share/src/nxusb && make -f Makefile

In my case,  /usr/NX/bin/drivers/nxusb.ko already existed. But re-compilation generated a different size nxusb.ko file (a little bigger in size).

Copying the new /usr/NX/share/src/nxusb/nxusb.ko  onto /usr/NX/bin/drivers/nxusb.ko and restarting the server solved the issue. I did the same re-compilation and copying on the client as well; but I am not sure this was necessary.

What happens with Windows versions of NoMachine  and how to solve any problems (if there are any at all) with Windows servers and clients is not within my scope of interest.  I never tried it.