lost and found ( for me ? )

Linux Mint 12 : FreeNX

[ install NX server on Linux Mint ]

Linux Mint 12 ( NX server )   ------- Win7 ( NX Client ) 

hat2 ~ # tail -1 /etc/lsb-release

hat2 ~ # uname -ri
3.0.0-14-generic i386

download Free edition NX server , node and client deb pakage as below.
# ls
nxclient_3.5.0-7_i386.deb  nxnode_3.5.0-7_i386.deb  nxserver_3.5.0-9_i386.deb

install deb packages.
  92  dpkg -i nxclient_3.5.0-7_i386.deb
  93  dpkg -i nxnode_3.5.0-7_i386.deb
  94  dpkg -i nxserver_3.5.0-9_i386.deb

Seen from the documentation , server , node and client are required on NX server.

[ set up NX server ]

administration manual

- about configuration files and binary files

configuration directory for the server and the node is /usr/NX/etc
# ls /usr/NX/etc/*
/usr/NX/etc/administrators.db         /usr/NX/etc/passwords.db.lock
/usr/NX/etc/administrators.db.lock    /usr/NX/etc/passwords.db.sample
/usr/NX/etc/administrators.db.sample  /usr/NX/etc/profiles.db
/usr/NX/etc/guests.db                 /usr/NX/etc/profiles.db.lock
/usr/NX/etc/guests.db.lock            /usr/NX/etc/profiles.db.sample
/usr/NX/etc/guests.db.sample          /usr/NX/etc/server-debian.cfg.sample
/usr/NX/etc/node-debian.cfg.sample    /usr/NX/etc/server.cfg
/usr/NX/etc/node.cfg                  /usr/NX/etc/server.lic
/usr/NX/etc/node.lic                  /usr/NX/etc/users.db
/usr/NX/etc/nodes.db                  /usr/NX/etc/users.db.lock
/usr/NX/etc/nodes.db.lock             /usr/NX/etc/users.db.sample

node.localhost.id_dsa  node.localhost.id_dsa.pub

server.cfg is for the server and node.cfg is for the node.

the binary files are installed under /usr/NX/bin
# ls /usr/NX/bin/*
/usr/NX/bin/nxagent   /usr/NX/bin/nxnode    /usr/NX/bin/nxservice  /usr/NX/bin/nxuexec
/usr/NX/bin/nxclient  /usr/NX/bin/nxprint   /usr/NX/bin/nxspool
/usr/NX/bin/nxesd     /usr/NX/bin/nxsensor  /usr/NX/bin/nxssh
/usr/NX/bin/nxkill    /usr/NX/bin/nxserver  /usr/NX/bin/nxstat

- configuration

# egrep -v ^# server.cfg | grep -v ^$
ConfigFileVersion = "2.0"
EnablePasswordDB = "0"

ConfigFileVersion = "2.0"
CommandFuser = "/bin/fuser"
CommandXmodmap = "/usr/bin/xmodmap"
CUPSBinPath = ""
CUPSSbinPath = ""
EnableCUPSSupport = "0"
MountShareProtocol = "both"
#CommandStartGnome = "/etc/X11/Xsession gnome-classic.session"
#CommandStartGnome = "/usr/bin/gnome-session --session=gnome"
CommandStartGnome = "/usr/bin/gnome-session --session=gnome-classic" <- GUI setting

I specified “CommandStartGnome = "/usr/bin/gnome-session --session=gnome-classic” by reference to the following output.
# ps aux | grep gnome-session | grep -v grep
117       5312  0.0  0.4  49168  8688 ?        Ssl  02:09   0:00 /usr/bin/gnome-session --session=gnome
117       5363  0.0  0.0   3856   180 ?        Ss   02:09   0:00 /usr/bin/ssh-agent /usr/bin/dbus-launch --exit-with-session /usr/bin/gnome-session --session=gnome
117       5366  0.0  0.0   3748   484 ?        S    02:09   0:00 /usr/bin/dbus-launch --exit-with-session /usr/bin/gnome-session --session=gnome

Seen from /usr/share/gnome-session/sessions/ direcotry , I found that I could choose gnome or gnome-classic or gnome-fallback or ubuntu-2d and ubuntu for “gnome-session --ssesion=” option.
# ls /usr/share/gnome-session/sessions/*

- start the server
hat2 ~ # /usr/NX/scripts/init/nxserver start
Trying to start NX server:
NX> 122 Service started.
NX> 999 Bye.
Trying to start NX statistics:
NX> 700 Starting NX statistics.
NX> 700 Start

hat2 ~ # /usr/NX/bin/nxserver --status
NX> 900 Connecting to server ...
NX> 110 NX Server is running.
NX> 999 Bye.

[ install NX client on Win 7 64bit ]

download the NX client as below

I installed nxclient-3.5.0-7.exe.
The installation is very easy , launch exe file and then click next , next..

start NX client.
Enter any name as the session to connect to the NX server ( Mint ) and click configure.

enter IP address  , Desktop , Display settings and then click save and OK.

connect to the NX server ( Linux Mint ) from NX Client ( Windows )

enter the username and credentials and specify the session name , then click Login.

can connect to the NX server.

# /usr/NX/bin/nxserver --list
NX> 127 Session list:

Display Username                         Remote IP       Session ID                       Node
------- -------------------------------- --------------- -------------------------------- -----------
1012    hattori                          192.168.11.x   ZZZZZZZZ localhost:22

NX> 999 Bye.

[ tips ]

I faced the following three problems.

1. can’t enter underscore
2. when I enter letter ‘d’ , all windows are minimized
3. the keyboard layout has been changed from Japanese to English

1. can’t enter underscore

Here the excerpt of the keyboard mapping by “ xmodmap -pke” command.
I checked the keycode number from the output of xev command.
# xmodmap -pke
keycode 123 = XF86AudioRaiseVolume NoSymbol XF86AudioRaiseVolume  <- wrong
keycode 133 = Super_L NoSymbol Super_L <- wrong

log on to the NX server locally not remotely and dump the keyboarad mapping by “xmodmap -pke”
$ xmodmap -pke ~/.Xmodmap

edit .Xmodmap
$ egrep '(123|133)' .Xmodmap
keycode 123 = backslash underscore backslash underscore
keycode 133 = backslash bar backslash bar

.Xmodmap will be loaded when establishing the NX session.

If you have faced the keyboard mapping problems , please check the keycode setting by xev and edit .Xmodmap to correct it.

2. when I enter letter ‘d’ , all windows are minimized

GUI -> system tool -> system setting -> keyborad -> shortcut

disable “Hide all normal windows”

3. the keyboard layout has been changed from Japanese to English

edit the NX client ( not NX server ) configuration file.

open Linux Mint12 notebook.nxs file with text editor.
configuration files are storedx under C:\Users\Username\.nx\config\ directory.

add the following parameter.
<option key="Custom keyboard layout" value="jp" />


  1. Hi,
    Nice post, save me a lot of time..

    BTW, works like a charme, no problems!


  2. Hello,
    Thank you for your comment.

    > BTW, works like a charme, no problems!
    I'm lazy worker :D

  3. Thanks for sharing your experience; the line "/usr/bin/gnome-session --session=gnome" has solved my problem. - Dietmar

  4. UPDATE For Mint Mate 13 - the gnome classic fails.

    I found the following works for me: edit “/usr/NX/etc/node.cfg" :

    CommandStartGnome = "/usr/bin/mate-session"

    ie -- no options set

    then start the Client with Gnome settings.

    hope this helps someone.


Note: Only a member of this blog may post a comment.