New Contributor
Posts: 5
Registered: ‎12-12-2017
Accepted Solution

Impala query that is "Executing" but query status is "Finished"



We're on version CDH 5.12.2.

On Cloudera Manager, Impala -> Query , I see query that is "Executing" but query status is "Finished".

query_duration was 42/51 mins.


User is running query on Hue.


I've searched through official papers, google it, but getting nowhere.

Did user left Hue before getting query result?


Can anyone give me explanation on this?


Thank you!


Expert Contributor
Posts: 108
Registered: ‎02-23-2018

Re: Impala query that is "Executing" but query status is "Finished"

Hi @Hail2Ichi,


Try to update Impala JDBC Connector.




Posts: 1,004
Kudos: 31
Solutions: 20
Registered: ‎05-27-2014

Re: Impala query that is "Executing" but query status is "Finished"

Hi @Hail2Ichi ,


Hue does not close the connection to Impala until the results page is clicked on. Clicking the results page in Hue executes the fetchresults call to Impala.


Since Impala queries are client driven ( for example, until client calls fetch to complete fetching entire result set), the query still remains in a running state. And when a query has not been closed/unregistered, Impala shows it in the In Flight section in its web UI. Cloudera Manager shows all In Flight queries as Executing.


To mitigate this problem, we need to ask Impala to kill any idle sessions if not used, so that resources will be released. In order to do this, we need to set the timeout value for the idle sessions. When a session ends, all its sessions are closed. Follow below steps:


  1. From Cloudera Manager UI, navigate to Impala > Configuration > Service-Wide > Advanced > Impala Command Line Argument Advanced Configuration Snippet (Safety Valve).
  2. Set session timeout parameter (value is in seconds). 

    --idle_session_timeout=<the maximum lifetime of your queries>

Note: How long to timeout the session will depend on end users' usage. Ideally to be at least 1-2 hours so that Hue user does not have to keep refreshing the Impala Editor page. Example: 


We also document above in more detail in below knowledge article:

Finished Queries show as Executing in the Cloudera Manager Impala Queries Page:


Thanks and hope this helps,


Li Wang, Technical Resolution Manager

Was your question answered? Make sure to mark the answer as the accepted solution.
If you find a reply useful, say thanks by clicking on the thumbs up button.

Learn more about the Cloudera Community:

Terms of Service

Community Guidelines

How to use the forum

New Contributor
Posts: 5
Registered: ‎12-12-2017

Re: Impala query that is "Executing" but query status is "Finished"

Thank you!

We're planning to move from Hue now.



New Contributor
Posts: 4
Registered: ‎10-19-2018

Re: Impala query that is "Executing" but query status is "Finished"

idle session timeout didn't help me. It seems Hue keeps Impala connection and keeps communicating with Impala coordinator when the query is in flight. The only way to close any open connection is to logoff from the HUE or Close the HUE session from http://<<Query-Coordinator>>:25000/sessions.