Good afternoon.
To clear the memory, we planned to restart executor every night.
Unfortunately, an error occurs at the time of restart:
05-Feb-2020 13:31:26.813 SEVERE [KNIME-RMI-Retirer_0] com.knime.enterprise.server.executor.rmi.RMIExecutorManagerImpl.rmiReachedEndOfLife Failed to start new RMI instance - using the old instance instead com.knime.enterprise.utility.ExecutorException: Could not start new RMI instance as all available ports are currently in use at com.knime.enterprise.server.executor.rmi.RMIExecutorManagerImpl.startNewRMI(RMIExecutorManagerImpl.java:310) at com.knime.enterprise.server.executor.rmi.RMIExecutorManagerImpl.rmiReachedEndOfLife(RMIExecutorManagerImpl.java:206) at com.knime.enterprise.server.executor.rmi.RMIExecutorManagerImpl.lambda$startNewRMI$0(RMIExecutorManagerImpl.java:325) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748)
I see that you run on a Windows machine. IIRC there has been a Windows update that blocked the ports used by the executor. Could you check that the necessary ports are available? They start at port 50100 and then the port will be increased by 1 if the port isn’t available.
I checked the ports and in the range 50101-51800 there are no ports used. In the log I do not see that knime is trying to use another port only 50100.
Another interesting fact is that after an error occurs (with a reserved port), knime no longer tries to restart according to a schedule, even there are no error messages.
the error might be misleading. Windows might block the ports using their firewall and hence no program is listening to that port. It could be that 50100 is unblocked while all others are blocked.
We checked the settings and logs of the firewall, it is disabled and there are no messages about blocking ports in the logs. From experience, there may still be options, what can block ports?
Disabled firewall and antivirus, unfortunately the situation and the error did not change. I tried with the changed port and completely without specifying the port. Maybe you have any tips or suggestions for diagnosing the problem?
Hi Roland!
Changed the port to 40100, unfortunately the situation is the same.
10-Feb-2020 13:03:07.340 INFO [KNIME-RMI-Retirer_0] com.knime.enterprise.server.executor.rmi.RMIExecutorManagerImpl.rmiReachedEndOfLife RMI Executor 0 (user: (none), port: 40100, uptime: 00:10:00, status: AcceptingJobs, #jobs: 0) needs to be retired; starting new instance and shutting it down
10-Feb-2020 13:03:07.340 SEVERE [KNIME-RMI-Retirer_0] com.knime.enterprise.server.executor.rmi.RMIExecutorManagerImpl.rmiReachedEndOfLife Failed to start new RMI instance - using the old instance instead
com.knime.enterprise.utility.ExecutorException: Could not start new RMI instance as all available ports are currently in use
at com.knime.enterprise.server.executor.rmi.RMIExecutorManagerImpl.startNewRMI(RMIExecutorManagerImpl.java:310)
at com.knime.enterprise.server.executor.rmi.RMIExecutorManagerImpl.rmiReachedEndOfLife(RMIExecutorManagerImpl.java:206)
at com.knime.enterprise.server.executor.rmi.RMIExecutorManagerImpl.lambda$startNewRMI$0(RMIExecutorManagerImpl.java:325)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Is it possible that an executor is still running in the background and prevents the start of the new one? Could you please try to shutdown the server and stop/kill all remaining KNIME executor processes? An other possible way to make sure that there is no remaining process would be a restart of the Windows on the server.
What did you do before the issue occurs, did you perform an update of the KNIME server or a change in the configuration? I would like to have a look on your configuration file /config/knime-server.config. Please send me a PM if you don’t want to attach it here.
Completely stopped the server, checked that there were no executor, and started the server again. The server automatically starts the executor. At that moment, when the executor must restart, the old one is still active.
Is it possible that you set the option com.knime.server.executor.max_instances=1 in the knime-server.config, so that the start of the second instance is blocked?
The old one will be shut down after the successful start of the new one.