You want the ability to remotely access a Linux box from your Windows PC. You have some Linux applications you want to use that are not available on Windows, or there are times when all you have is a Windows box to do your remote Linux administration from.
Additionally, you want a full graphical session to run satisfactorily over a slow link, even dial-up, and you want to be able to use the Linux desktop or window manager of your choice.
You don't want much! Fortunately, FreeNX was designed just to fulfill these needs. Follow these steps to get up and running.
Install the FreeNX server on the Linux box you want to log in to remotely.
Next, add authorized users to the FreeNX server. You must create the login name and password separately. The FreeNX users must already have Linux accounts on the server:
# nxserver --adduser pinball
NX> 100 NXSERVER - Version 1.5.0-50 OS (GPL) NX> 1000 NXNODE - Version 1.5.0-50 OS (GPL) NX> 716 Public key added to: /home/pinball/.ssh/authorized_keys2 NX> 1001 Bye. NX> 999 Bye# nxserver --passwd pinball
NX> 100 NXSERVER - Version 1.5.0-50 OS (GPL) New password: Password changed. NX> 999 Bye
Strangely enough, you only get one chance to enter the password, so be careful.
Then, make sure the OpenSSH daemon is running on the FreeNX server, and port 22 is not blocked by your firewall.
Go to NoMachine.com (http://www.nomachine.com/) to download a free client for your Windows box. Make sure it has the same major and minor version numbers as the FreeNX server. You can find the FreeNX server version number with this command:
# nxserver --version
NX> 100 NXSERVER - Version 1.5.0-50 OS (GPL)
So, your client needs to be version 1.5.x. If you cannot find a matching client, please see the Discussion.
Once you have a matching client, you can set up your login from Windows.
Click on NX Client For Windows to open the Connection Wizard, as Figure 8-2 shows.
Enter a name for this configuration on the Session line; for example, let's call our new session windbag1.
Enter the hostname or IP address of the server on the Host line.
Select your type of connection, and click Next.
On the Desktop window, select Unix. Then, select the Linux desktop you want to see on your remote session, and the size of the window, as in Figure 8-3.
Check the Enable SSL box to encrypt all traffic, then click Next.
Check "Create shortcut on desktop" and Nxclient will make a shortcut called windbag1. Make sure your login name has the correct case, type in your password, click to log in, and there you are. Figure 8-4 shows an active session.
To close your FreeNX session, log out from your remote desktop in the usual manner. You may also click the Close button on the Nxclient window. This brings up a dialog that asks you if you want to Suspend or Terminate. Suspend does not close running applications, so you can log in later and pick up where you left off; Terminate closes all applications.
If you try to connect to the server and get the error message: "Unable to create the X authorization cookie," it means Nxclient is looking in the incorrect location for the xauth program. Fix this by creating a symlink:
# cd /usr/X11R6/bin
# ln -sf /usr/bin/xauth
When NoMachine released its 2.0 versions, it left FreeNX behind. FreeNX 1.5 doesn't work with NoMachine 2.0 clients without a bit of tweaking, and even then, it may not work reliably. At the time this was written, you could download older NoMachine clients from Industrial-Statistics.com: http://www.industrial-statistics.com/info/nxclients?IndStats=47ebcaa422e76eba8af14a1b6f31d971.
Another option is to modify FreeNX 1.5 to work with the NoMachine 2.0 client. See FreeNX FAQ/Problem Solving: http://openfacts.berlios.de/index-en.phtml?title=FreeNX_FAQ/Problem_Solving.
Nxclient, by default, enters the name of the current Windows user on the Nxclient login screen, with the first letter capitalized. Linux logins are case-sensitive, so beware. You may log in as any FreeNX user; it doesn't matter which Windows login is active.
You may save your password in the Nxclient login; this is convenient, but an obvious security risk.
Enabling SSL encrypts all traffic, and is good to use all the time.
You'll probably want to increase the font size used in the logfiles; the default is nearly unreadable. Do this on the Environment tab; open "NX Client For Windows," then click the Configure button to get to all the configuration tabs.
You may use any desktop environment or window manager, as long as it is installed on the FreeNX server. However, when this was written, selecting anything other than KDE or Gnome didn't work correctly.
When a new user is added to the FreeNX server, the user key is copied from /etc/nxserver/users.id_dsa.pub to /home/user/.ssh/authorized_keys2.
FreeNX user's passwords are hashed and stored in /etc/nxserver/passwords.
NoMachine's download page:
http://www.nomachine.com/download.php |
nomachine.com's Support Center:
http://www.nomachine.com/support.php |
NX Server System Administrator's Guide:
http://www.nomachine.com/documentation/admin-guide.php |