Request stop in Rapidminer Server

AlphaPi
AlphaPi New Altair Community Member
edited November 5 in Community Q&A
Hello everyone,

I was running a process in Rapidminer server. When i wanted to stop it, i pressed the "Request stop" button. But still, this process is encountered among the "Running" processes. How can i stop this process and delete it from the Executions tab?

Thanks in advance

Best Answer

Answers

  • aschaferdiek
    aschaferdiek New Altair Community Member
    edited May 2020
    Hi icsdm217003! I assume that you're using our latest Server release 9.6? It's known that some executions keep appearing as running. This will be handled in the upcoming release by introducing a force stop option which will kill the executing Job Container forcibly. For now your only option is to restart the Job Container/Job Agent executing the Job. The job will be flagged as timeout if you do so. If not, you could jump into the underlying database, look for the job and change its state manually to STOPPED.
    This is a potentially destructive operation, ensure that it's only affecting the one job you like to change the state of.
    // Get all jobs in running state, but you probably only want the one ID from the job you like to stop
    SELECT * FROM jobservice_job WHERE state = 'RUNNING';

    // Use the ID column to update the state
    UPDATE jobservice_job SET state = 'STOPPED' WHERE id = 'The-ID-You-Found-Out-In-The-Query-Above';


  • AlphaPi
    AlphaPi New Altair Community Member
    Hi aschaferdiek, I am using the server through the browser. Is there any solution, in this case? 

  • Nikouy
    Nikouy New Altair Community Member
    edited May 2020
    Please note that the table name is jobservice_job and not jobservice_jobs

    <i>rmsdb=> SELECT * FROM jobservice_job</i><br><i>jobservice_job&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; jobservice_job_context_in&nbsp;&nbsp;&nbsp;&nbsp; jobservice_job_error</i><br><i>jobservice_job_agent&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; jobservice_job_context_macro&nbsp; jobservice_job_log</i><br><i>jobservice_job_context&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; jobservice_job_context_out&nbsp;&nbsp;&nbsp; </i>

  • aschaferdiek
    aschaferdiek New Altair Community Member
    Yes, I'll adapt the original answer. Thanks for pointing that out.
  • Nikouy
    Nikouy New Altair Community Member
    I'd like to highlight that this introduces several problems when using an external message broker. It will mess up all the job agents. Therefore, the solution is purging the queue directly from the message broker. >>> https://activemq.apache.org/how-do-i-purge-a-queue

    RM Server should have an option to Force Stop all enqueues messages (i.e. jobs), and this action should purge the queue in the external broker and at the same time update the DB.


  • aschaferdiek
    aschaferdiek New Altair Community Member
    edited June 2020
    As already mentioned, you need to shut down all Job Agents otherwise they keep sending updates.
    Starting from 9.6 there's a 'purge queue' solution integrated into RapidMiner Server. https://docs.rapidminer.com/latest/server/configure/queues/index.html#purge-process-executions
    9.7 includes a mechanism to force stop an execution.