NX node: stop working after several hours

Forums / NoMachine for Linux / NX node: stop working after several hours

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #8271
    unlim
    Participant

    I install and use fresh new NX 4x client with my VDS (CentOS 6x, openVZ based).

    All works OK.

    I log out from NX and after several hours try to login again.

    Now login not proceed with error “The connection with the server was lost”.
    I turned off firewall – that does not help.

    If I reboot my VDS – then I can login w/o problem.
    But after that this problem happens again.

    How to fix it?
    I press “Save logs” on NX client and see such records in session file:

    *************
    Info: Connection to IP  port 4000 started at 18:07:21 244.140.
    1492 2412 18:07:21 776.367 ClientSession: A valid certificate for this server was found.
    1492 132 18:07:24 818.359 ClientSession: Going to query for available services.
    1492 132 18:07:25 032.226 UiRemoteSessionList: Going to automatically select the first session.
    1492 132 18:07:25 136.718 ClientSession: Going to query for available services.
    1492 132 18:07:25 236.328 ClientSession: Going to attach session at index ‘0’.
    1492 132 18:07:25 237.304 Keyboard: Current model ‘evdev’ session model ‘evdev’ layout ‘en_US’ variant ‘(empty)’ options ‘(empty)’.
    1492 132 18:08:22 858.398 Connection: WARNING! Ignoring the I/O error and waiting for the daemon error reporting.
    Info: Connection to IP port 4000 closed at 18:08:22 858.398.
    1492 132 18:08:22 858.398 Connection: Connection at 0x051c9610 failed.
    1492 132 18:08:22 859.375 ClientSession: Runnable at 0x051c9610 caused the session at 0x003ed9a0 to fail.
    1492 132 18:08:22 859.375 ClientSession: Failing reason is ‘The connection with the server was lost’.
    1492 132 18:08:22 863.281 ClientSession: Stopping session at 0x003ed9a0.
    1492 132 18:08:22 873.046 Connection: Stopping connection at 0x051c9610.
    1492 132 18:08:22 874.023 ClientDaemonConnector: Stopping the current connection.
    1492 132 18:08:22 874.023 Connection: Stopped connection at 0x051c9610.
    1492 132 18:08:22 895.507 ClientSession: Stopped session at 0x003ed9a0.
    *************

    /usr/NX/var/log/nxserver.log from the VDS contains the following:
    *************
    2015-09-20 18:11:42 948.270 31675 NXSERVER User ‘user’ logged in from ‘IP’.
    2015-09-20 18:11:44 333.019 31675 NXSERVER WARNING! NXPL::NXConnectLocal cannot connect to localhost:21982: EADDRINUSE from main::send_command_to_server.
    2015-09-20 18:11:45 287.632 31675 NXSERVER WARNING! NXPL::NXConnectLocal cannot connect to localhost:21982: EADDRINUSE from main::send_command_to_server.

    2015-09-20 18:11:48 906.291 31675 NXSERVER WARNING! NXPL::NXConnectLocal cannot connect to localhost:21982: ESRCH from main::send_command_to_server.
    2015-09-20 18:11:49 861.263 31675 NXSERVER WARNING! NXPL::NXConnectLocal cannot connect to localhost:21982: ESRCH from main::send_command_to_server.

    2015-09-20 18:12:03 704.151 31675 NXSERVER WARNING! NXPL::NXConnectLocal cannot connect to localhost:21982: ENOTTY from main::send_command_to_server.
    2015-09-20 18:12:15 164.995 31675 NXSERVER WARNING! NXPL::NXConnectLocal cannot connect to localhost:21982: ENOTTY from main::send_command_to_server.

    2015-09-20 18:12:22 048.040 31675 NXSERVER ERROR! Cannot attach to main server.
    2015-09-20 18:12:22 048.148 31675 NXSERVER WARNING! Cannot write to FD#12.
    2015-09-20 18:12:22 048.200 31675 NXSERVER WARNING! Error is: 32, ‘Broken pipe’.
    2015-09-20 18:12:22 817.196 31675 NXSERVER WARNING! NXPL::NXConnectLocal cannot connect to localhost:21982: ENOTTY from main::send_command_to_server.
    2015-09-20 18:12:23 771.814 31675 NXSERVER WARNING! NXPL::NXConnectLocal cannot connect to localhost:21982: ENOTTY from main::send_command_to_server.

    *************

    #8299
    Haven
    Contributor

    Hello unlim,
    One of the possible issue that fits described symptoms is crash of
    ‘nxserver –daemon’ process. This process is vital to provide access
    to the physical display. Unfortunately we need full nxserver logs to
    find what is exactly going on.
    Please follow the instructions here:
    https://www.nomachine.com/AR07K00677
    Reproduce the issue, please gather logs and send them to forum[at]nomachine[dot]com

    As a note, a common case is that the ‘nxserver –daemon’ process
    crashes due to “Too many open files” error. If you see in nxserver.log
    file error: Error is: 24, 'Too many open files'.
    Please follow the instructions from article to fix this:
    How to avoid ‘Too many open files’ messages while opening a NX session

    • This reply was modified 6 years, 3 months ago by Haven.
    • This reply was modified 6 years, 3 months ago by Haven.
    #8304
    unlim
    Participant

    I collect and just send the logs…

    #8316
    Haven
    Contributor

    hello unlim,
    Thank you for sending the logs.
    In nxserver.log file we can find: Error is: 24, 'Too many open files'.

    Did you try follow the article:
    How to avoid "Too many open files" messages while opening a NX session
    from my previous post?

    #8325
    unlim
    Participant

    I perform now all the steps from that instruction – but problem not gone.

    I just sent fresh logs.

    Could you pls see?
    Thank you!

    #8334
    Haven
    Contributor

    Hello unlim,
    Let’s investigate further.
    Please follow those instructions and if possible provide full commands output.

    Please keep debug level log in server.cfg file and perform server restart:
    /etc/NX/nxserver --restart

    then execute:
    ps -Af | grep nx

    Find nxserver --daemon process PID, and check its limits:
    cat /proc/<nxserver --daemon PID>/limits
    It’s necessary to verify especially the fields ‘Max open files’

    Please check also user limits after that ‘nxserver –restart’ command was performed:

    ulimit -aS
    ulimit -aH

    If limits are set correctly, please send output of those command with new set of logs.

    #8371
    unlim
    Participant

    Just sent…

    #8410
    Haven
    Contributor

    Hello unlim,
    Thank you for new set of logs. Unfortunately I still cannot identify the issue.
    We know that running nxserver –daemon process:
    nx 13809 1 7 22:38 pts/0 00:00:00 /usr/NX/bin/nxserver.bin root 13770 --daemon
    has limit of 1024 open files. It should be more then enough to work properly.

    The issue on your system occurs after several hours after ‘restart’.
    Could please you keep debug level in the server and provide new set of logs
    when the nxserver --daemon process will be lost due to error: ‘Too many open files’ ?

    #8460
    Haven
    Contributor

    Hello unlim,
    Thanks for bearing with me during the investigation.
    We have identified the issue and have opened a Trouble Report:
    http://www.nomachine.com/TR10M06073
    You can use the ‘alert me’ check box to know when we have a fix.
    You could also apply the described workaround.
    Please remember to restart nxserver after changing server.cfg file.

    #8482
    unlim
    Participant

    That solution works.

    Thank you!

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

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