在HIVE中运行查询时如何更改Tez职位名称 [英] How to change Tez job name when running query in HIVE
问题描述
当我使用Tez提交Hive SQL时,如下所示:
When I submit a Hive SQL using Tez like below:
hive (default)> select count(*) from simple_data;
在Resource Manager UI中,作业名称显示类似HIVE-9d1906a2-25dd-4a7c-9ea3-bf651036c7eb
的名称,是否可以将作业名称更改为my_job_nam
?
In Resource Manager UI the job name shows something like HIVE-9d1906a2-25dd-4a7c-9ea3-bf651036c7eb
Is there a way to change the job name tomy_job_nam
?
如果我不使用Tez并在MR中运行作业,则可以使用set mapred.job.name
设置作业名称.
If I am not using Tez and running the job in MR, I can set the job name using set mapred.job.name
.
我需要设置任何Tez参数来更改作业名称吗?
Are there any Tez parameters I need to set, to change the job name?
感谢您的任何投入.
推荐答案
知道了这一点.使用属性hive.session.id
可以更改名称.下面是一个示例.
Got this figured out. Using the property hive.session.id
the name could be changed. Below is an example.
hive --hiveconf hive.session.id=test_$(date '+%Y%m%d_%H%M%S') \
-e "select month, max(sale) from simple_data group by month;"
这篇关于在HIVE中运行查询时如何更改Tez职位名称的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!