How to kill a given job started by a hive?

I am currently working with CDH 5.1. It starts the normal work of Hadoop on YARN , but the hive still works with mapred . Sometimes a large request will hang for a long time, and I want to kill it.

I can find this great job on the JobTracker web console until it provides a button to kill it.

Another way is to kill on the command line. However, I could not find the work performed by the command line.

I tried 2 commands:

  • yarn application -list
  • mapred job -list

How to kill a big request like this?

+6
source share
1 answer

You can get the Job ID from the Hive CLI when starting the job or from the web interface. You can also list job IDs using the application ID from the resource manager. Ideally, you should get everything from

 mapred job -list 

or

 hadoop job -list 

Using the job id, you can kill it using the command below.

 hadoop job -kill <job_id> 

Another alternative would be to kill the application using

 yarn application -kill <application_id> 
+14
source

Source: https://habr.com/ru/post/982362/


All Articles