NX technology
Encyclopedia
NX technology is a computer program
Computer program
A computer program is a sequence of instructions written to perform a specified task with a computer. A computer requires programs to function, typically executing the program's instructions in a central processor. The program has an executable form that the computer can use directly to execute...

 that handles remote X Window System
X Window System
The X window system is a computer software system and network protocol that provides a basis for graphical user interfaces and rich input device capability for networked computers...

 connections, and attempts to greatly improve on the performance of the native X display protocol
X Window System protocols and architecture
In computing, the X Window System is a network-transparent windowing system for bitmap displays. This article details the protocols and technical structure of X11.-Client–server model and network transparency:...

 to the point that it can be usable over a slow link such as a dial-up modem
Modem
A modem is a device that modulates an analog carrier signal to encode digital information, and also demodulates such a carrier signal to decode the transmitted information. The goal is to produce a signal that can be transmitted easily and decoded to reproduce the original digital data...

. It wraps remote connections in SSH
Secure Shell
Secure Shell is a network protocol for secure data communication, remote shell services or command execution and other secure network services between two networked computers that it connects via a secure channel over an insecure network: a server and a client...

 sessions for encryption.

It is developed by Gian Filippo Pinzari at the Italian
Italy
Italy , officially the Italian Republic languages]] under the European Charter for Regional or Minority Languages. In each of these, Italy's official name is as follows:;;;;;;;;), is a unitary parliamentary republic in South-Central Europe. To the north it borders France, Switzerland, Austria and...

 software company NoMachine.
The NX scheme was derived from that of DXPC – the Differential X Protocol Compressor project.

NX software is currently available for Windows, Mac OS X, Linux, and Solaris. NoMachine has clients available for Windows and Mac OS X, and Google makes a freely available Open Source GPL2 version of the server called NeatX.

Technical details

NX compresses
Data compression
In computer science and information theory, data compression, source coding or bit-rate reduction is the process of encoding information using fewer bits than the original representation would use....

 the X11 data to minimize the amount of data transmitted. NX takes full advantage of modern hardware by caching
Cache
In computer engineering, a cache is a component that transparently stores data so that future requests for that data can be served faster. The data that is stored within a cache might be values that have been computed earlier or duplicates of original values that are stored elsewhere...

  all manner of data to make the session as responsive as possible. For example the first time a menu is opened it may take a few seconds, but on each subsequent opening the menu will appear almost instantly.

NX is faster than its predecessors, as it eliminates most of the X round-trips
Round-trip delay time
In telecommunications, the round-trip delay time or round-trip time is the length of time it takes for a signal to be sent plus the length of time it takes for an acknowledgment of that signal to be received...

, while dxpc and MLView only compress data.

The two principal components of NX are nxproxy and nxagent. nxproxy is derived from dxpc and is started on both the remote (client in X terminology) and the local (server in X terminology) machines simulating an X server on the client and forwarding remote X protocol requests to the local X server.

Typical setup:

remote clients (xterm, etc.)

nxproxy client

Network

nxproxy server

local X server (monitor/keyboard)

nxproxy alone achieves 1:10 to 1:1000 compression ratios reducing bandwidth, but does not eliminate most of X's synchronous round trips, which are mostly responsible for X's perceived latency.

nxagent in turn is derived from Xnest
Xnest
Xnest is an X Window System server that shows its output in a window. In other words, Xnest opens a window that works like another screen in which the user can open windows, etc....

 and is typically started on the remote (client) machine, thus avoiding most X11 protocol round trips. Together with nxproxy (which is built into nxagent) this setup performs well over low bandwidth/high latency links:

remote clients (xterm, etc.)

nxagent server side \
nxagent client side nxagent executable
nxproxy client /

Network

nxproxy server

local X server (monitor/keyboard)

On systems with a functional X11 implementation, nxproxy and nxagent are all that is needed to establish a connection with low-bandwidth requirements between a set of remote X clients and the local X server. SSH can be used to establish a secure tunnel between the two hosts involved.

FreeNX and the various NX Clients are used for setup, handling suspend and resume, secure tunnelling over SSH, and for printing and sound.

Other display protocols

Although designed primarily to optimize X11 sessions, NX server can be configured as a proxy server
Proxy server
In computer networks, a proxy server is a server that acts as an intermediary for requests from clients seeking resources from other servers. A client connects to the proxy server, requesting some service, such as a file, connection, web page, or other resource available from a different server...

 to tunnel Remote Desktop Protocol
Remote Desktop Protocol
Remote Desktop Protocol is a proprietary protocol developed by Microsoft, which provides a user with a graphical interface to another computer. The protocol is an extension of the ITU-T T.128 application sharing protocol. Clients exist for most versions of Microsoft Windows , Linux, Unix, Mac OS...

 (for Windows Remote Desktop Services sessions) and remote Virtual Network Computing
Virtual Network Computing
In computing, Virtual Network Computing is a graphical desktop sharing system that uses the RFB protocol to remotely control another computer...

 sessions (most modern general-purpose operating system
Operating system
An operating system is a set of programs that manage computer hardware resources and provide common services for application software. The operating system is the most important type of system software in a computer system...

 platforms), giving them some of the same speed improvements.

Use of SSH protocol and how SSH tunneling works in NX

NX uses the SSH
Secure Shell
Secure Shell is a network protocol for secure data communication, remote shell services or command execution and other secure network services between two networked computers that it connects via a secure channel over an insecure network: a server and a client...

 protocol to send its data. SSH was chosen as a base for NX because of its excellent security record. NX relies on both the SSH functionalities and the existing OpenSource SSH software, to make it possible to run contemporary Unix and Windows desktops and arbitrary network applications, across the Internet, in a secured and controlled way.

The way NX works (NX 3.x) is by creating an 'nx' user on the server machine whose shell is executed any time a remote NX user connects to SSH using NX Client. The initial login between client and server happens using a DSA key-pair. The public key-part is provided during the installation of the server: the private key-part is distributed together with NX Client. The SSH server is forced by the NX key to execute the nxserver shell and enables SSH X11 forwarding. Due to performance deterioration of SSHD, X11 forwarding was introduced in NX 2.0.0.

The SSH secure channel is established once the client has been authenticated on the server. Authentication of the user on the system and negotiation of session parameters happen on this channel. By default, NX Client is configured with encryption of all traffic enabled, i.e. NX tunnels all the session traffic over the encrypted SSH channel used to authenticate and negotiate the session with the server.

Starting from version 4.0, NX will also allow system login as an alternative method, so that users can choose if they want to rely on NX or SSH authentication..

In addition to simply allowing users to log in remotely over a slow internet link to a server graphically, NX also allows them to suspend and resume sessions. During suspension, the processes invoked inside the session continue to run, and so many people have come to use NX as a graphical alternative to SSH
Secure Shell
Secure Shell is a network protocol for secure data communication, remote shell services or command execution and other secure network services between two networked computers that it connects via a secure channel over an insecure network: a server and a client...

 and the 'screen
GNU Screen
GNU Screen is a software application that can be used to multiplex several virtual consoles, allowing a user to access multiple separate terminal sessions inside a single terminal window or remote terminal session...

' application - in order to run applications such as XChat permanently on a computer with a fixed internet link. Another program that serves this purpose is xpra
Xpra
xpra or X Persistent Remote Applications is a tool which allows you to run X programs usually on a remote host and then direct their display to your local machine without losing any state. It differs from standard X forwarding in that it allows disconnection and reconnection without disrupting the...

.

License

Up until version 4.0, NoMachine used the GNU General Public License
GNU General Public License
The GNU General Public License is the most widely used free software license, originally written by Richard Stallman for the GNU Project....

 for the core NX technology, while at the same time offering non-free commercial NX solutions for the enterprise, free client and server products for Linux
Linux
Linux is a Unix-like computer operating system assembled under the model of free and open source software development and distribution. The defining component of any Linux system is the Linux kernel, an operating system kernel first released October 5, 1991 by Linus Torvalds...

 and Solaris and free client software for Microsoft Windows
Microsoft Windows
Microsoft Windows is a series of operating systems produced by Microsoft.Microsoft introduced an operating environment named Windows on November 20, 1985 as an add-on to MS-DOS in response to the growing interest in graphical user interfaces . Microsoft Windows came to dominate the world's personal...

, Mac OS X
Mac OS X
Mac OS X is a series of Unix-based operating systems and graphical user interfaces developed, marketed, and sold by Apple Inc. Since 2002, has been included with all new Macintosh computer systems...

 and embedded systems.

On December 21, 2010, NoMachine announced that the upcoming NX 4.0 release would be closed-source only.

Due to the free software nature of older releases of NX, the FreeNX project was started in order to provide the wrapper scripts for the GPL NX libraries. FreeNX is developed and maintained by Fabian Franz.

2X develops another commercial terminal server
Terminal server
A terminal server enables organizations to connect devices with an RS-232, RS-422 or RS-485 serial interface to a local area network . Products marketed as terminal servers can be very simple devices that do not offer any security functionality, such as data encryption and user authentication...

 for Linux that also uses the NX protocol.

On July 7, 2009, Google
Google
Google Inc. is an American multinational public corporation invested in Internet search, cloud computing, and advertising technologies. Google hosts and develops a number of Internet-based services and products, and generates profit primarily from advertising through its AdWords program...

 announced their open-source NX server, Neatx
Neatx
Neatx is an open-source NX server based on NoMachine's NX technology. It is created by Google. Neatx is written mostly in Python, with the exception of very few wrapper scripts in BASH and one program written in C.- History :...

.

Clients

The primary client for use with NX is the official freeware NoMachine NX Client, but there are several projects underway to produce an open source
Open source
The term open source describes practices in production and development that promote access to the end product's source materials. Some consider open source a philosophy, others consider it a pragmatic methodology...

 client.

The most mature of the projects used to be Lawrence Roufail's nxc client library. This is a full library which can be used for other clients to build upon, and another application, 'nxrun', is provided which makes use of this library. , the library does not support suspending or resuming sessions, nor does it support using any compression method other than JPEG
JPEG
In computing, JPEG . The degree of compression can be adjusted, allowing a selectable tradeoff between storage size and image quality. JPEG typically achieves 10:1 compression with little perceptible loss in image quality....

 for the graphics.

The kNX project was a proof-of-concept application written by Joseph Wenninger. This was meant to eventually become a complete NX client, showing that an open-source client could be written. However, this implementation got stuck in an incomplete stage; to date it lacks many important features. As such, kNX was effectively useless. In late 2005, Fabian Franz and George Wright started to change kNX to use the nxc library, but quickly abandoned the project.

More recent open-source efforts include QtNX, which offers full suspend and resume support. However, this has been reported not to work with the most recent NX libraries.

An update to nxclientlib (which was the core of QtNX) called nxcl has been completed by Seb James in September 2007. nxcl is an update to nxclientlib and works with version 3 of the NX core libraries. It also drops the Qt dependency which prevented nxclientlib from becoming widely used as a cross-platform basis for NX client programs. nxcl provides both a library which can be linked to in a client program (libnxcl), and a self-contained NX client with a D-Bus
D-Bus
In computing, D-Bus is a simple inter-process communication open-source system for software applications to communicate with one another. Heavily influenced by KDE2–3's DCOP system, D-Bus has replaced DCOP in the KDE 4 release. An implementation of D-Bus supports most POSIX operating...

 API (the nxcl binary). nxcl is available from the FreeNX Subversion server.

Other recent and actively maintained OSS NX clients include OpenNX a "drop-in replacement for Nomachine's [proprietary] nxclient". OpenNX supports full suspend and resume.

Various open source terminal server projects such as x2go also use the NX protocol; however, x2go is not compatible with other NX servers and clients.

Another recent GTK+ remote desktop client project Remmina
Remmina
Remmina is a remote desktop client for Linux-based operating systems, written in C, that supports the RDP, VNC, NX, XDMCP and SSH protocols. It is in the package repositories for Debian versions 6 and later and for Ubuntu versions since 10.04 . As of 11.04 , it replaced tsclient as the default...

 announced NX protocol support in its latest release 0.8.

Previous X11 compression schemes

  • lbxproxy - Low Bandwidth X (obsolete and of historical interest only)
  • dxpc The Differential X Protocol Compressor

See also

  • Comparison of remote desktop software
  • Thinstation
    Thinstation
    Thinstation is a free and open source Linux implementation of a thin client operating system. It only requires standard 32-bit x86 PC hardware and can boot directly from the network via PXE or Etherboot from a TFTP server, or from local devices such as Hard disks, CompactFlash drives, USB keyrings...

     thin client Linux implementation with optional built-in NX client.
  • GNU Screen
    GNU Screen
    GNU Screen is a software application that can be used to multiplex several virtual consoles, allowing a user to access multiple separate terminal sessions inside a single terminal window or remote terminal session...

     - a terminal multiplexer for console-mode (text-mode) applications
  • Xpra
    Xpra
    xpra or X Persistent Remote Applications is a tool which allows you to run X programs usually on a remote host and then direct their display to your local machine without losing any state. It differs from standard X forwarding in that it allows disconnection and reconnection without disrupting the...

     - a system for attaching and deattaching remote X programs
  • Neatx
    Neatx
    Neatx is an open-source NX server based on NoMachine's NX technology. It is created by Google. Neatx is written mostly in Python, with the exception of very few wrapper scripts in BASH and one program written in C.- History :...

     - an open source NX implementation created by Google
  • xmove
    Xmove
    xmove is a computer program that allows the movement of X Window System applications between different displays and the persistence of X applications across X server restarts. It solves a problem in the design of X, where an X client is tied to the X server it was started on for its lifetime...

     - a tool allows you to move programs between X Window System displays (outdated)
  • guievict
    Guievict
    guievict is a computer program which enables the GUI of any application for XFree86 implementation of X Window to be transparently migrated to or replicated on another display...

     - a system for checkpointing and migrating the GUI of an X window application

External links

  • NoMachine - official site offering client and commercial server.
  • NoMachine technical documentation - describes Vanilla X and NX server.
  • FreeNX project page on BerliOS
    BerliOS
    BerliOS is a project founded by FOKUS, a Fraunhofer Institute located in Berlin, to coordinate the different interest groups in the field of open source software and to assume a neutral coordinator function...

    .
  • WinSwitch an applet for easily starting, suspending and sending NX sessions between computers (and also Xpra
    Xpra
    xpra or X Persistent Remote Applications is a tool which allows you to run X programs usually on a remote host and then direct their display to your local machine without losing any state. It differs from standard X forwarding in that it allows disconnection and reconnection without disrupting the...

    , VNC, RDP
    Remote Desktop Protocol
    Remote Desktop Protocol is a proprietary protocol developed by Microsoft, which provides a user with a graphical interface to another computer. The protocol is an extension of the ITU-T T.128 application sharing protocol. Clients exist for most versions of Microsoft Windows , Linux, Unix, Mac OS...

    and more)
  • Release announcement of the QtNX client.
  • OpenNX project page SourceForge.
  • x2go terminal server.
  • Article series on FreeNX (LinuxJournal): Part 1 -- Part 2 -- Part 3 -- Part 4 -- Part 5 -- [Part 6 is missing from publication].
  • Faster remote desktop connections with FreeNX - Article from Linux.com on NX technology and FreeNX in particular.
  • DotRiver uses NX technologies and offers a free trial. You can test NX there.
  • DXPC Home page Differential X Protocol Compressor by Kevin Vigor.
  • Neatx Neatx is an Open Source NX server developed by Google, similar to the commercial NX server from NoMachine.
  • Remmina The GTK+ Remote Desktop Client
  • http://openssh.org The OpenSSH project
  • QVD Linux Opensource VDI platform using NX as the transport protocol
The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK