Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Kill hive queries without exiting from hive shell

Is there any way we can kill hive query without exiting from hive shell ?. For Example, I wrongly ran the select statement from some table which has million rows of data, i just wanted to stop it, but not exiting from the shell. If I pressed CTRL+Z, its coming out of shell.

like image 319
Padmanabhan Vijendran Avatar asked Jan 09 '17 12:01

Padmanabhan Vijendran


1 Answers

You have two options:

  1. press Ctrl+C and wait till command terminates, it will not exit from hive CLI, press Ctrl+C second time and the session will terminate immediately exiting to the shell

  2. from another shell run

    yarn application -kill <Application ID> or mapred job -kill <JOB_ID>

like image 109
leftjoin Avatar answered Sep 21 '22 16:09

leftjoin