Since I don’t like having to work on my projects across multiple machines, I’ve found that having access to my home network can be extremely useful. I liked the idea of vnc, but the paranoia of running a vanilla vnc session out in the open scares me. Sure, you can tunnel it through ssh, but in in the end it is painfully slow. So, keeping all my wishes in mind, I set out looking for something with minimal setup, something that was relatively secure, and gave me as many of the benefits of being behind my computer physically.
The very first time I ran across NoMachines NXServer was when I admin’ed for the family business. I drooled at its ability to fill the Remote Desktop gap for Linux: how it could put me right in front of the business’ server securely and quickly while I was out of town. However, our budget was a huge constraint so NXServer was out of the question. I eventually had to settle for Vnc over ssh and my hair still hasn’t grown back.
Sometime since then, NoMachine started offering a free version of NXServer that allows at most two concurrent connections and two users (the full feature comparison between their offerings is listed here). There is an open source solution that doesn’t have these limitations called FreeNX, but I just want something quick to setup on the first round….
Before checking it out, be sure you have Openssh server and stdc++2.0 installed, then grab the client, node, and server files from their website. They have the .deb’s and .rpm’s available here.
Since I’m running Ubuntu, I downloaded the .debs, placed them in my home directory, and then ran (line breaks are put in for readability):
$sudo dpkg -i nxclient_3.2.0-14_i386.deb nxnode_3.2.0-11_i386.deb nxserver_3.2.0-13_i386.deb
That sets up the basic configuration and starts the server. Below, I’ve listed a couple more steps I needed to get running on Ubuntu.
First, you’ll need to add the loopback home (127.0.0.1) to your hosts.allow file for NXServer to run properly. Add this line:
ALL: 127.0.0.1
If you want a more secure server, you can restrict access to ssh by adding the following to your /etc/hosts.allow (replacing <my ip address> with your actual ip address):
SSHD: .my.secure.domain,<my ip address>
With the above line, you need to deny all other locations from ssh attempts. You can do this by adding the following to your /etc/hosts.deny :
SSHD: ALL
If you find yourself having problems with xauth locking your .Xauthority make sure you have the proper permissions using (replacing <username> with your username):
$> chown -R <username>:<username> /home/<username>/.Xauthority $> chmod 600 /home/<username>/.Xauthority
If you still have problems, try breaking the xauth locks and renaming the file by:
$> xauth -b $> mv /home/<username>/.Xauthority /home/<username>/.Xauthority.backup
Note: If you are using the Mac nxclient, you will need to have X11 installed. You can grab the latest for Leopard here.
Now I’m able to work on my desktop machine from anywhere in the world. Let us know what you think!

















August 24th, 2008 at 11:15 am
I have it up and running and can see my desktop, but can not do anything – no response from any mouseclick, etc. I do not have compiz running on the server.
Any suggestions?
Thanx for a great post! I have been looking for an equivalent of RDP in windows!
August 24th, 2008 at 10:00 pm
In the past, there have been problems where running X11 in rootless mode can result in user input being discarded. Do you have a rootless session running, or are you able to use your keyboard? I know there is at least one outstanding bug that prevents a user from using their mouse after opening up the Evolution Calendar application, are you doing this by any chance? Also, what are the specifics on your setup (what versions are you running, what OS is on the client and server, and what Window Manager are you)?
August 27th, 2008 at 3:32 pm
Thanx for th reply. I should have gotten back to you earlier. I had a virtalbox running XP that crashed and locked up gnome. Up and running smoothly now
August 29th, 2008 at 9:37 am
You’re welcome! I’m glad it is working now.
October 3rd, 2008 at 1:36 pm
I want to run an application using WINE. Using this software, will each TS session have it’s own .wine config running such that each connection is it’s own “windows profile”? Or will all connections use the same config all accessing the application as one user multiple times?
October 8th, 2008 at 8:19 am
First let me say that NoMachine restricts the nxserver free edition to allow only 2 simultaneous logins and only 2 users (check here). To answer your question, yes, each terminal session does have its own .wine config, but it is the .wine config associated with the user id you logged in with. Of course this means that all connections will not use the same config because you can only have 1 terminal session per userid. This helps ensure that local files, like your .wine config, aren’t being updated at the same time by two different sessions. This behavior essentially mimics that of Remote Desktop for Windows.
I hope that helps! Please let us know if you have any more questions!
November 4th, 2008 at 11:25 pm
Hi rgomez,
Very interesting topic, I have two Quetions:
1. Do I need “real ip” on my PC to login remotely?
2. Can I access with my PC from Windows OS?
November 5th, 2008 at 9:39 pm
Thanks for the Comment, let me address your questions:
For your first question, I’m assuming you mean that you are behind a router or firewall. If this is the case you need to make sure that your router or firewall will allow port 22 access to the box running the NXServer. Meaning you will have to open port 22 to the net, and possibly forward it to your server. Currently I have a Linux box setup on my network with a local static ip, and use my router to forward external port 22 connects directly to my NXServer box. For additional security, I restrict access to my box by only allowing IP’s I trust using the /etc/hosts.allow file.
For your second question, of course! The beauty of NoMachines product is that you can grab a client for any major operating system (Windows, Mac OS X, Solaris, and of course Linux). You can grab the latest NXClient for Windows here.
I hope this helps, thanks for stopping by!
November 6th, 2008 at 2:30 am
Thanks a lot rgomez for your answers,
Now evething is understandable (clear). I have tested and it works, thanks a lot for this post. I will now try FreeNX open source version.
November 6th, 2008 at 11:01 am
You are very welcome, I’m glad I could help! Thanks for the comment and taking the time to check out our site!
-Ray Gomez