How do I control a hive job name but keep the stage info?

后端 未结 3 1101
自闭症患者
自闭症患者 2021-01-08 00:31

I have a number of hive queries that my system executes on a regular basis. When you look at the job tracker, they show up as \"SELECT field, other_field ..... (Stage-1)\"

相关标签:
3条回答
  • 2021-01-08 01:01

    I know this is a very late reply but anyways if this helps let me know.

    This happens because HIVE does not allow certain parameters to be set at run time. Still if you want to set it follow the following steps:

    1. Log in into Ambari UI as admin.
    2. Go to hive Configs
    3. Open custom HiveSite.xml
    4. Add following key value pair
      KEY: hive.security.authorization.sqlstd.confwhitelist.append
      VALUE: mapred.job.name
    5. Restart HIVE service

    You can any key-value pair in this config for which you get this runtime error

    0 讨论(0)
  • 2021-01-08 01:04

    I've found this site: https://cwiki.apache.org/confluence/display/Hive/AdminManual+Configuration

    on it there is a property called: hive.query.string

    so set hive.query.string = even more helpful name should work.

    It works perfectly for me.

    0 讨论(0)
  • 2021-01-08 01:05

    I'm not sure there is a way to implement exactly what you wish but I can offer something else.
    Instead of using set mapred.job.name you can add a comment in the beginning of the query with a more helpful name like this :
    -- this is a more helpful name
    SELECT field, other_field ....

    Then, in the jobtracker you'll see -- this is a more helpful name ..... (Stage-%d)"

    0 讨论(0)
提交回复
热议问题