Reply To: Error: Cannot create a new display, please contact your system administrator

NoMachine for Linux / Error: Cannot create a new display, please contact your system administrator / Reply To: Error: Cannot create a new display, please contact your system administrator

#29260
submarinersubmariner
Participant

Thank you for the very quick and helpful reply. I was indeed missing the Desktop Environment (I had mistakenly assumed that it would get included as a dependency when I installed Firefox).

So I did:

$ sudo apt update

$ sudo apt upgrade

$ sudo apt install ubuntu-desktop

all of which completed successfully.

Unfortunately, I’m still unable to connect to the desktop using NoMachine. The behavior is different now. During the ~3 minutes (it failed much more quickly previous to the desktop installation) that the NoMachine connection attempt was in process, my ssh session to the same machine became unresponsive (which I interpreted to mean that the NoMachine connection attempt to start up the desktop remotely was consuming a great deal of bandwidth, so I waited patiently), but after ~3 minutes or so, ultimately the local NoMachine app reported:

The session negotiation failed.

Error: Cannot create a new display, please contact your system administrator

On the remote server side for this connection attempt, logs indicated:

$ sudo tail -f /usr/NX/var/log/nxserver.log

2020-08-31 12:20:20 048.417 16795 NXSERVER User ‘ubuntu’ logged in from ‘xxxx’ using authentication method NX-password.
2020-08-31 12:23:12 568.173 16833 NXNODE WARNING! NXClientMonitor: NXClient –monitor is not ready to accept initialization messages for 120 seconds. Reach timeout to send.
2020-08-31 12:23:17 843.420 16833 NXNODE ERROR! NXClient –monitor exceeded maximum initialize time of ‘120’ seconds.
2020-08-31 12:23:33 668.458 16833 NXNODE WARNING! NXClientMonitor: NXClient –monitor with pid 16894 did not exit within 5 seconds. Killing process.
2020-08-31 12:23:39 084.325 16833 NXNODE WARNING! Process ‘/usr/NX/bin/nxclient –monitor –pid 16874’ with pid ‘16894/16894’ finished with signal 9 after 196,977 seconds.
2020-08-31 12:23:39 369.020 16815 NXSERVER ERROR! Node reported monitor failure. Killing attached sessions.
2020-08-31 12:23:39 381.314 16833 NXNODE ERROR! Cannot create a virtual session.
2020-08-31 12:23:39 381.423 16833 NXNODE ERROR! Cannot connect to NoMachine monitor.
2020-08-31 12:23:39 478.049 16815 NXSERVER ERROR! Received error message from node ‘localhost:4000’, ‘Cannot connect to NoMachine monitor.’.
2020-08-31 12:23:41 391.002 6976 NXSERVER ERROR! NXFrameBuffer failed to start.
2020-08-31 12:23:41 411.218 6976 NXSERVER ERROR! Received error message from nxserver NX> 500 ERROR: Cannot connect to NoMachine monitor.
2020-08-31 12:23:41 412.268 16795 NXSERVER ERROR! Received error from nxserver –daemon NX> 500 ERROR: Cannot connect to NoMachine monitor.
2020-08-31 12:23:41 862.407 17616 NXSERVER WARNING! Cannot write to FD#1.
2020-08-31 12:23:41 862.555 17616 NXSERVER WARNING! Error is: 32, ‘Broken pipe’.
2020-08-31 12:23:41 886.519 16795 NXSERVER User ‘ubuntu’ from ‘xxxx’ logged out.

remote:
~$ sudo /etc/NX/nxserver –status
NX> 111 New connections to NoMachine server are enabled.
NX> 162 Enabled service: nxserver.
NX> 162 Disabled service: nxnode.
NX> 162 Enabled service: nxd.

remote:

$ ls -al ~/.Xauthority
-rw——- 1 ubuntu ubuntu 0 Aug 31 12:23 /home/ubuntu/.Xauthority

Looking at the EC2 instance monitoring tab does indeed show a large spike in network activity (>100MB in and out) and CPU utilization.

I tried it a second time and found the the ssh session became unresponsive for more than 30 minutes after the second attempt, even after I quit NoMachine on the local side. I was also unable to get a response to a second attempt to ssh into the remote machine.

I followed instructions at the link you provided for installing the desktop environment (substituting equivalent Ubuntu commands in place of RH commands).

Any other thoughts on what I can do to troubleshoot and/or solve this problem?