Still cannot find default environment after TR09N07188 fix

Forums / NoMachine for Linux / Still cannot find default environment after TR09N07188 fix

Viewing 15 posts - 1 through 15 (of 18 total)
  • Author
    Posts
  • #13022
    AvatarEddieA
    Participant

    This is a continuation of my previous post.

    I upgraded to 5.1.62 as per the Trouble Report.  However, I still get the “Cannot find default environment” when starting a session.

    Re-captured the logs and attached.

    Cheers.

     

    #13082
    AvatarMth
    Contributor

    Hello

    First of all, it seems that there is something wrong with configuration files.
    Can you please send us whole /usr/NX/var/log directory along with /usr/NX/etc/server.cfg
    and /usr/NX/etc/node.cfg for investigation?

    To fix it please try a clean installation – uninstall, remove the /usr/NX directory then install again.

    If this does not help, please enable the logs as described here: https://www.nomachine.com/DT04M00076
    then do /etc/NX/nxserver –restart as administrator and send us the /usr/NX/var/log directory.

    Also it would help to debug the source of problem if you include the output of

    ps awwxo uid,ppid,pid,sid,comm,args

    when logged on to desktop.

    Please send the logs to forum[at]nomachine[dot]com referencing the post topic in the mail title.

    #13089
    AvatarEddieA
    Participant

    First thing I did was save off the files: /usr/NX/etc/server.cfg and /usr/NX/etc/node.cfg.  I can forward them on, if still needed.  The log directory was attached to my previous post.

    I then uninstalled NX and did an “rm -r /usr/NX” to (hopefully) remove all remnants.

    Next, I (re-)installed version 5.1.62.  Trying to connect from Windows 10, I now get this message:  Cannot run startkde.  Please ensure that the requested application is in the system PATH and that you have the appropriate credentials to execute it.

    So, I did a “find” on startkde and it threw up just one copy in /usr/bin/startkde, with permissions:  -rwxr-xr-x  And obviously, /usr/bin, is available in the PATH to all users.

    Logs an ps output captured and attached.

    Cheers.

     

    #13189
    AvatarMth
    Contributor

    Hello

    It seems the server has trouble with finding working display. Can you give us
    the output of:

    # lsof -a -c Xorg -U

    And if it gives any output, also:

    # /bin/netstat -ln –protocol=unix

    # ls /tmp/.X11-unix/

    If the output include any sockets named like

    /tmp/.X11-unix/X0

    please make sure that netstat has access rights on at least 755.

    If not, there is a possibility that Xorg server has disabled listening on unix sockets, which are vital for connecting via NoMachine. Are you aware of any changes made in this regard? (any changes
    in system configuration files, startx script etc.)

    #13237
    AvatarEddieA
    Participant

    Sorry, I’ve been out of town for a few days and only just saw this.

    At what point are you asking for these commands to be run, as I am not using NoMachine to connect to an existing X11 session.  I an using the option to create a session on connection as per https://www.nomachine.com/FR10L02842.

     

    This works perfectly on Slackware 14.1 with KDE 4.14.3, but not Slackware 14.2 with KDE 5.16.07.

     

    Cheers.

     

    #13401
    AvatarMth
    Contributor

    Hello.

    It seems that the problem lies in DefaultDesktopCommand key from node.cfg.

    Please find this key in the /usr/NX/etc/node.cfg file. By default it should look like:

    DefaultDesktopCommand “/usr/bin/dbus-launch –exit-with-session startkde”

    You need to change the startkde to full path to this program eg:

    DefaultDesktopCommand “/usr/bin/dbus-launch –exit-with-session /usr/bin/startkde”

    If this does not help please edit the /usr/bin/startkde file by adding

    set -x

    line at the start.

    Then please make sure that the SessionLogClean key in /usr/NX/etc/node.cfg
    is uncommented and set to 0.

    SessionLogClean 0

    reproduce the problem and send us the logs again.

    #13441
    AvatarEddieA
    Participant

    OK, one more step along this time, so beginning to make progress.

    On trying to connect, I got the “User connected” pop-up instead of the previous error, but then instead of the KDE start-up splash I just got a black screen with a simple, white, pop-up window that said:  “Could not start D-Bus. Can you call qdbus?”.

    Stopped NX, updated /usr/bin/startkde, cleared the old logs, and started NX.  Reproduced issue and collected server logs.  Attached.

    This line in one of the node logs caught my eye:  /usr/bin/startkde: line 25: qtpaths: command not found

     

    So, it looks like the $PATH from the environment is not making it into the NX start.

    I updated that line in /usr/bin/startkde to have the full path for qtpaths, and tried again.  This time, no pop-up, but again no KDE splash screen and just a black background.  I didn’t bother capturing the logs for this, as I’m sure it’s just going to show the same type of “command not found” error, but just later in the process.

     

    Cheers.

     

    #13469
    AvatarEddieA
    Participant

    Another update.

    Looking through some of the scripts that are executed at NX start-up, that manipulate PATH, I found:  /etc/NX/etc/nxserver.  Turning on debug for this script, I see the following where it checks the current setting of PATH:

    + test x = x

    + export PATH=/bin:/usr/bin

    Which could explain why later in the process I see this error, as mentioned above:

    /usr/bin/startkde: line 25: qtpaths: command not found

    But not why /usr/bin/startkde is not found. Strange.

    Cheers.

     

    #13512
    AvatarBritgirl
    Keymaster

    After many attempts, we’ve finally been able to reproduce it. It would appear to be more of a problem with KDE 5, not NoMachine. Whilst we investigate further, it might be better to use an alternative desktop environment until we’ve identified a workaround. When we have some more info we’ll post it here.

    #13546
    AvatarEddieA
    Participant

    Looking at the traces I pulled from /etc/NX/nxserver and /etc/NX/nxnode, to me it looks like these are both called without the underlying PATH from root being propagating through. Aren’t these both called before startkde is invoked, which is the reason for the initial “Cannot find default environment” issue.

    Cheers.

    #13575
    AvatarBritgirl
    Keymaster

    Yes, the proper path is not being received (but this is just the tip of the iceberg) We’ll update the topic once we’ve got some more info.

    #14245
    AvatarEddieA
    Participant

    Any progress on this ??

     

    Cheers.

     

    #14255
    AvatarBritgirl
    Keymaster

    Sorry for not providing any further news on this. It’s in the queue, we promise 😉

    #14457
    Avatarzaq
    Contributor

    Hello EddieA

    Could you set in your Slackware /usr/NX/etc/node.cfg:

    DefaultDesktopCommand "/usr/bin/startSession.sh"

    Put attached script to /usr/bin/ and set this permissions:

    chown root:root /usr/bin/startSession.sh

    chmod 555 /usr/bin/startSession.sh

    and try to run NoMachine connection to your Slackware.

    • This reply was modified 3 years, 9 months ago by Avatarzaq.
    • This reply was modified 3 years, 9 months ago by Avatarzaq.
    #14512
    AvatarEddieA
    Participant

    OK, that seems to work.  Thank you.

    Cheers.

    BTW  It was pure chance I spotted this update, as I didn’t get an e-mail, despite having the “Notify me” box ticked.  Now on to reporting the issue I have with an ARM installation.  🙂

Viewing 15 posts - 1 through 15 (of 18 total)

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