Cannot connect to physical desktop issue / Ubuntu 16.04 running MATE Desktop

Forums / NoMachine for Linux / Cannot connect to physical desktop issue / Ubuntu 16.04 running MATE Desktop

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #16085
    danslak
    Participant

    Recently I’ve been unable to connect to my Ubuntu 16.04.3 LTS physical desktop (running MATE desktop) using NoMachine, from Windows 10. Both are running the latest version (5.3.12), free versions. I get the “Cannot detect any display running. Do you want NoMachine to create a new display and proceed to connect to the desktop?” message. However, some display IS running, as I can connect to it using x2go, but that is so terribly slow it is not useable. When I restart nxserver, it also suggests there is no display available:

    # /etc/init.d/nxserver restart
    NX> 162 Disabled service: nxserver.
    NX> 162 Disabled service: nxnode.
    NX> 162 Disabled service: nxd.
    NX> 161 Enabled service: nxserver.
    NX> 162 WARNING: Cannot find X servers running on this machine.
    NX> 162 WARNING: A new virtual display will be created on demand.
    NX> 161 Enabled service: nxd.

    But lightdm is running, as well as Xorg:

    # ps -ef | grep lightdm
    root      2254     1  0 Oct14 ?        00:00:00 /usr/sbin/lightdm
    root      2263  2254  1 Oct14 tty7     00:59:16 /usr/lib/xorg/Xorg -core :0 -seat seat0 -auth /var/run/lightdm/root/:0 -nolisten tcp vt7 -novtswitch
    root      6563  2254  0 Oct14 ?        00:00:00 lightdm –session-child 12 21

    # ps -ef | grep X
    nx 1037 23979 0 20:57 ? 00:00:01 /usr/NX/bin/nxserver.bin -c /etc/NX/nxserver –login -H 4
    root 2263 2254 1 Oct14 tty7 00:59:16 /usr/lib/xorg/Xorg -core :0 -seat seat0 -auth /var/run/lightdm/root/:0 -nolisten tcp vt7 -novtswitch
    root 7843 2197 0 Oct14 ? 00:00:46 XBESClientUI
    nx 23815 1 0 20:36 ? 00:00:01 /usr/NX/bin/nxserver.bin –daemon
    nx 23979 23815 0 20:36 ? 00:00:00 /usr/NX/bin/nxd

    I believe it will create a virtual display (the few times I’ve tried), but I do not want this – I need to connect to the existing physical desktop.

    I believe this changed with a recent kernel and/or X update on the Ubuntu machine, maybe ~2 weeks ago. Previous to that, it would mostly work, but would require a two-step login: I’d connect initially, and get the lock screen (with MATE logo, exactly as if I was at they physical machine). I’d  then unlock it, and screen goes black. I then disconnect the client, and reconnect, and it would then come up (without further lock screen or login) to the physical desktop and be perfectly functional.

    Now, I still go through the lock screen step, but disconnecting and then reconnecting then brings up the “cannot detect a display” error.

    When it used to work, it would typically (or always…this was over past few months….before that, this didnt occur) come up with a list of two displays to connect to, one owned by root, and one by my username. I would need to choose the root one, which would bring me to the lock screen, as above. Choosing the display owned by myself would result in a blank screen.  And also, at times, I would sometimes get the same “Cannot detect any display running” message, but if I waited a few minutes, this would go away, and it would then show the two root and username display options, allowing me to proceed.

    I’ve looked around the forums (and logs) but havent found anything that helps. I did change the DefaultDesktopCommand to mate-session in node.cfg as I’m running MATE:

    DefaultDesktopCommand “/usr/bin/mate-session”

    but no dice, and it had worked previously without any edits to node.cfg (it had been set to “/etc/X11/Xsession ‘gnome-session –session=ubuntu'”).

    Thanks for any recommendations or suggestions of what to look for.

    Dan

     

    #16111
    og00r
    Contributor

    Can you look for any information in nxerror.log (/usr/NX/var/log/)? There could be something related to NXWMRunning.

    Also logs in /var/log/lightdm/ and /var/log/Xorg.*.log should be checked for errors.

    #16173
    danslak
    Participant

    Thanks for the suggestions. A day or two after making the above post, it of course began working perfectly, without requiring the double-connection, and with none of the warnings/errors about available display. It had not ever worked seamlessly like that in MANY months. Unfortunately, it did not last, and am back in the originally described scenario above.  (despite many reboots and nxserver restarts).

    Below are some of the error messages from nxerror.log. First I’ll post some lines that repeat every ~30 seconds, even when I’m not making any attempts to connect (nor have since last system reboot):

    2220 18237 20:25:19 372.490 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.
    Invalid MIT-MAGIC-COOKIE-1 key2220 18256 20:25:19 385.917 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.
    Invalid MIT-MAGIC-COOKIE-1 key2220 18257 20:25:19 386.373 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.
    … (8 repeats of above line) …
    Invalid MIT-MAGIC-COOKIE-1 key2220 18266 20:25:19 389.330 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.
    25710 25710 20:25:23 481.689 Io/Io: WARNING! Can’t find pid monitor for 18375.
    No protocol specified

    When I attempted to login tonight (during which I get to, and past, the MATE login screen), there’s also a message about display :1 (which I assume is the login screen? although it does “open” as I see it and enter my username/pw), but then back to the display :0 warnings, and other errors at the end of the connection attempt:

    Invalid MIT-MAGIC-COOKIE-1 key2220 17855 20:24:49 087.901 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.
    Invalid MIT-MAGIC-COOKIE-1 key2220 17856 20:24:49 088.269 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.
    Invalid MIT-MAGIC-COOKIE-1 key2220 17857 20:24:49 088.630 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.
    2220 18218 20:25:19 357.383 HostWmRunningHelper: WARNING! Failed to open display ‘:1’.
    /usr/bin/xauth:  file /var/run/lightdm/root/:1 does not exist
    No protocol specified
    2220 18237 20:25:19 372.490 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.
    Invalid MIT-MAGIC-COOKIE-1 key2220 18256 20:25:19 385.917 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.

    Invalid MIT-MAGIC-COOKIE-1 key2220 18265 20:25:19 389.086 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.
    Invalid MIT-MAGIC-COOKIE-1 key2220 18266 20:25:19 389.330 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.
    25710 25710 20:25:23 481.689 Io/Io: WARNING! Can’t find pid monitor for 18375.
    No protocol specified
    2220 18310 20:25:23 548.219 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.
    Invalid MIT-MAGIC-COOKIE-1 key2220 18319 20:25:23 563.214 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.
    Invalid MIT-MAGIC-COOKIE-1 key2220 18320 20:25:23 563.920 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.
    Invalid MIT-MAGIC-COOKIE-1 key2220 18321 20:25:23 564.486 HostWmRunningHelper: WARNING! Failed to open display ‘:0’.

    kdestroy: No credentials cache found while destroying cache
    Info: Handler started with pid 18846 on Tue Oct 24 20:27:00 2017.
    Info: Handling connection from <MYIP> port 52463 on Tue Oct 24 20:27:00 2017.
    nxexecRemoveKerberosTicket: WARNING! Can’t remove ticket.
    nxexecRemoveKerberosTicket: Error is No such file or directory.
    Info: Connection from <MYIP> port 52463 closed on Tue Oct 24 20:27:39 2017.
    Info: Handler with pid 18846 terminated on Tue Oct 24 20:27:39 2017.
    Error: Invalid user .
    Info: Handler started with pid 19116 on Tue Oct 24 20:27:44 2017.
    Info: Handling connection from <MYIP> port 52490 on Tue Oct 24 20:27:44 2017.
    nxexecRemoveKerberosTicket: WARNING! Can’t remove ticket.
    nxexecRemoveKerberosTicket: Error is No such file or directory.

    Does any of that look particularly suspect or have a known solution?

    #16174
    danslak
    Participant

    Quick update: after composing the above post, the NoMachine login page then listed an available X server: “Physical display, root, Ubuntu X server on :1 0 “, instead of “no available sessions on this server” . I selected this server, which then got me back to the MATE login screen, and then (after waiting a few minutes, disconnecting, and then connecting again) back to the “no available sessions on this server” message.  Typically in the past, getting the root X server was good news, as this would let me in. (vs the username X server, which would not).

    #16190
    kroy
    Contributor

    We couldn’t reproduce such problem. Can you enable debug, restart nxserver (sudo /usr/NX/bin/nxserver --restart) and if problem appears – send logs and ~/.xsession-errors to forum[at]nomachine[dot]com.  Instructions about debug and collecting logs you can find there: https://www.nomachine.com/DT07M00098.

    #16210
    danslak
    Participant

    Ok, I’ve just now submitted the logs to the email address above.

    #16249
    kroy
    Contributor

    If you were able to reproduce problem – can you try disable XBESClientUI service and tell us the result of the test?

    #16259
    danslak
    Participant

    Yes – thank you! If I turn off the besclient service, and then restart nxserver, I can access with no problems whatsoever. I can then turn besclient service back on, and I can continue to connect, for some time (hours..not quite sure how many, but not overnight…), but at some point, besclient interferes again, and I then need to turn it off and restart nxserver to be able to connect.

    Based on the logs I sent, do you have any suggestions on workarounds to allow besclient to not interfere with nxserver? To be clear, they can both be running, as long as nxserver was started first, and connections work, for a number of hours. But then this breaks down and I get the error stating no display is available.

    #16266
    Britgirl
    Keymaster

    We’ve opened a Trouble Report. Please sign up to receive a notification of the fix when it’s available.
    https://www.nomachine.com/TR11O08235

Viewing 9 posts - 1 through 9 (of 9 total)

This topic was marked as solved, you can't post.