Announcement

Collapse
No announcement yet.

Can't log in with NX

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Can't log in with NX

    I have the latest version of NoMachine Free Client, Server and Node.
    Can't seem to connect from another computer on the same local network to my laptop
    When I try to log in, I see:
    The NX service is not available or the NX access was disabled on host 192.168.1.101
    Detail:
    NXSSH running with pid:13885
    Enabling check on switch command
    Enabling skip of SSH config files
    Setting the preferred NX options
    Connected to address: 192.168.1.101 on port:22
    authenticating user nx
    Using auth method: publickey
    Authetication failed.

    On the laptop that I am trying to connect to, I see:
    root@laptop:/etc/init.d# nxserver --usercheck volker
    NX> 900 Verifying public key authentication for NX user: volker.
    NX> 900 Adding public key for user: volker to the authorized keys file.
    NX> 716 Public key is already present in: /home/volker/.ssh/authorized_keys2.
    NX> 900 Verifying public key authentication for NX user: volker.
    NX> 500 ERROR: Public key authentication failed
    NX> 500 WARNING: NX server was unable to login as user: volker
    NX> 500 WARNING: Please check that the account is enabled to login.
    NX> 500 WARNING: Also check that user's home directory, the directory
    NX> 500 WARNING: ~/.ssh and the file ~/.ssh/authorized_keys2 have
    NX> 500 WARNING: correct permissions according to the StrictModes of
    NX> 500 WARNING: your SSHD configuration
    NX> 999 Bye.

    Also I see:
    root@laptop:~# nxserver --status
    NX> 900 Connecting to server ...
    NX> 204 Authentication to NX server failed.
    NX> 110 NX Server is stopped.
    NX> 999 Bye.
    And:
    root@laptop:~# nxserver --start
    NX> 500 Service already running.
    NX> 999 Bye.

    Can you help me sort this out?
    Thanks.

    #2
    Re: Can't log in with NX

    I take it to mean that you've set up openssh already, so let's check the setup of nxserver. In Konsole, type the following:

    Code:
    cd
    cde /usr/NXbin
    sudo ./nxserver --status
    Make sure you press enter at the end of each line. This should start the setup process for the user and verify that the nx server is running. If it's not, then you'll have to start it by invoking the command

    Code:
    sudo ./nxserver --start
    .

    So, let's proceed with the next command:
    Code:
    sudo ./nxserver --useradd username --administrator
    where 'username' is YOUR username, i.e, volker. This adds your name and grants you administrator rights. It's necessary as certain tasks need administrator rights and that in case you need to add users later.

    The above step creates both your user account and grants it admin rights. Verify that it's created with the following command:

    Code:
    sudo ./nxserver --userlist
    Now, to check everything is fine, authentication wise, and that initial error message you kept getting has gone, enter the following command in konsole:

    Code:
    sudo ./nxserver --usercheck username
    Although everything should be setup now, you'll might still run into problems as the firewall may block it. In case you still get an error message, install firestarter:

    Code:
     sudo apt-get install firestarter
    Then, open up firestarter Kmenu--->System------>firestarter. It will prompt you for your password. Enter it. Then go to the policy tab and right click in the "allow service" window and add rule. Choose SSH from the drop-down menu and port 22 is automatically selected. Leave the "apply for" value as anyone, click OK and click apply policy.

    Please note, that if you intend to connect from outside of your router, you'll have to setup portforwarding and it would be wise to change the default port 22 to something between 33000 to 60000.

    Please let me know if you have any problems thereafter.

    Challenges are what that keeps us from the borderline of boredom in life's journey. Linux user no. 419401 currently running Kubuntu 24.04
    _______________________________________________
    Current System: Beelink Mini PC, AMD Ryzen 7 5800H 8 Core(Up to 4.4GHz), 32GB DDR4 RAM 1TB NVME M.2 SSD, SER5 MAX Mini Desktop Computer with TCL BeyondTV5 serving as my monitor. ​

    Comment


      #3
      Re: Can't log in with NX

      To make sure it ain't the firewall try logging in via ssh like so:
      Code:
      ssh [email]user_name@ip.addr[/email]ess
      If that works it is down to NX - on your nx server you have to open systemsettings - advanced - session manager

      Now set it to "Restore manually saved session". Now go to the kde start icon and click on "save session". Now try again...

      This worked for me and took hours to find 'cos it is so unrelated.
      Once your problem is solved please mark the topic of the first post as SOLVED so others know and can benefit from your experience! / FAQ

      Comment


        #4
        Re: Can't log in with NX

        I had no end of trouble with NX after upgrading my NX box to hardy. I had tons of trouble with the upgrade from feisty to gusty as well. Eventually, I just purged the lot and reinstalled it all and it was working again.

        I was using freenx, though, so maybe it's a different situation.
        Dell Optiplex 580<br />Kubuntu 10.10 + backports

        Comment

        Working...
        X