Any utility that makes connecting to Windows NT/2000 Terminal Server from Linux clients easier is well worth a look. And rdesktop and PXES make it about as easy as possible. I’ll provide you with the information to install and run rdesktop and PXES, which I feel are two of the best solutions out there.

The rdesktop utility runs natively in Linux/UNIX
Windows Terminal Server uses the Remote Desktop Protocol (RDP) to provide client access to the terminal server. The rdesktop utility is an implementation of RDP that runs natively under any Linux or UNIX client running X Windows. To use it, you first need to download the latest version of rdesktop. For this article, I used rdesktop version 1.1.0 on a system running RedHat 7.3. In addition to having XFree86 running on the client computer, you must also install the XFree86 development libraries. (Note that the name and location of this package will depend on the distribution being used.) You install the development libraries with the following command:
rpm -ivh XFree86-devel-4.2.0-8.i386.rpm

Building and installing rdesktop
Once you’ve downloaded rdesktop, unpack the source code with the command:
tar -zxvf rdesktop-1.1.0.tar.gz

Enter the rdesktop 1.1.0 directory created when the code is unpacked. Next, configure the source code, compile the program, and install rdesktop with the following series of commands:
make install

Running rdesktop
Running rdesktop is very easy. The rdesktop command uses the following format:
rdesktop <options> <Server-IP or Server-name>

For example, to connect to the terminal server with the IP address, use the command:

All the options available with rdesktop are listed below:

  • -u: user name
  • -d: domain
  • -s: shell
  • -c: working directory
  • -p: password (autologin)
  • -n: client hostname
  • -k: keyboard layout (hex)
  • -g: desktop geometry (WxH)
  • -f: full-screen mode
  • -b: force bitmap updates
  • -e: disable encryption (French TS)
  • -m: do not sendmotion events
  • -l: do not request license

So to connect to a terminal server with the IP address and a user name and password supplied at the same time, you’d use the command:
rdesktop -u jim -p jim’s-password

PXES builds Linux-based thin clients
The rdesktop utility provides a very easy method for connecting to Windows Terminal Server, but there are other methods available. One of the best is PXES Linux, which is available from its project Web site. PXES is a micro distribution used to build Linux-based thin clients. This is useful for administrators who need to provide access to remote servers from client machines running minimal hardware. When installed, the PXES distribution can provide access to any XDMXCP server running on Linux or Solaris, and it even provides an implementation of rdesktop for access to Windows Terminal Server. Some of the advantages to using PXES include:

  • PXES boots from the network—no boot disk or boot EPROM is required on the client.
  • Almost any available hardware will run PXES.
  • PXES allows administrators to build the thinnest possible client while still enabling access to Windows Terminal Server. This can help reduce network security vulnerability.

The PXES machine receives its configuration and IP addressing information from a TFTP server and a DHCP server on the network. Once booted, the remote desktop GUI allows the user to connect to the terminal server.

The biggest advantage to using PXES with thin clients is its flexibility. While in this article I’ve focused on making connections to Windows Terminal Server, the thin clients created with PXES are also capable of connecting to the following servers:

  • XDM: XDMCP on UNIX/Linux
  • RDP: Microsoft Terminal Server
  • ICA: Citrix ICA server
  • VNC: VNC server
  • TELNET: Telnet server

Installing PXES
You install PXES in seven steps:

  1. Configure the kernel and initrd.
  2. Configure any required local devices.
  3. Configure any optional local devices.
  4. Set up X Windows.
  5. Configuring the specified session. If a Remote Desktop Protocol (RDP) session is selected, the following settings are required:
    RDP server: The IP address of the terminal server
    Domain: The domain used for the session
    User: The user accessing the terminal server
    Password: The user’s password
    Full screen: Used to select a full-screen session
    Desktop geometry: Set screen size when full screen is not used
    Force bitmap updates: Normally left unchecked
    Don’t send motion events: Normally left unchecked
    Don’t request license: Normally left unchecked
  6. Configure general options.
  7. Finish the configuration.

In most cases, the default provided by the PXES setup program will be sufficient. Once PXES is installed, you’re ready to connect to the remote server of your choice. PXES will also support a concurrent connection to different types of remote servers.