Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Killing HiveSessions with longer connection times

Solved Go to solution

Killing HiveSessions with longer connection times

Contributor

We have a requirement where, if there is any query which is taking up more time from HS2 session then terminate the connection and kill the job. To address this we have set below properties but we are seeing that jobs in YARN are not getting killed and running for more than two hours.

hive.server2.session.check.interval = 60000 (in ms) # 10 minutes hive.server2.idle.operation.timeout = 1800000 (in ms) # 30 minutes hive.server2.idle.session.timeout = 2400000 (in ms) # 40 minutes

Does setting below properties kill the related running YARN application after idle session time out. If not, is there any property which we need to set in HiveServer2 to kill long running queries.

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Killing HiveSessions with longer connection times

Super Guru
@Saikiran Parepally

Even if session gets timedout, YARN will retry attempt upto 3 more times and application will get killed if all 4 attempts are failed. That might be the reason why your YARN application runs longer.

Please refer below thread for more information.

https://qnalist.com/questions/4398360/how-to-terminate-a-running-hive-query-executed-with-jdbc-hive-...

2 REPLIES 2

Re: Killing HiveSessions with longer connection times

Super Guru
@Saikiran Parepally

Even if session gets timedout, YARN will retry attempt upto 3 more times and application will get killed if all 4 attempts are failed. That might be the reason why your YARN application runs longer.

Please refer below thread for more information.

https://qnalist.com/questions/4398360/how-to-terminate-a-running-hive-query-executed-with-jdbc-hive-...

Highlighted

Re: Killing HiveSessions with longer connection times

Contributor

@Kuldeep KulkarniThanks for your inputs,

Don't have an account?
Coming from Hortonworks? Activate your account here