Hi,

 

I have a cluster running HDP 2.3.4 with Oozie 4.2.0 installed on it. The 
cluster doesn’t use Kerberos. I’m trying to run a Hive2 action similar to the 
following

 

<workflow-app xmlns="uri:oozie:workflow:0.4" name="hive-wf">

    <parameters>...</parameters>

   

    <start to="hive-load"/>

 

    <action name="hive-load">

        <hive2 xmlns="uri:oozie:hive2-action:0.1">

            <job-tracker>${jobTracker}</job-tracker>

            <name-node>${nameNode}</name-node>

            <job-xml>${nameNode}/oozie/hive-site.xml</job-xml>

            <jdbc-url>${hiveServer}</jdbc-url>

            <script>${nameNode}/oozie /load-script.hql</script>

            <param>...</param>

        </hive2>

       

        <ok to="end"/>

        <error to="fail"/>

    </action>

 

    ...

 

        <ok to="end"/>

        <error to="fail"/>

    </action>

   

    <kill name="fail">

        <message>Hive failed, error 
message[${wf:errorMessage(wf:lastErrorNode())}]</message>

    </kill>

    <end name="end"/>

</workflow-app>

 

As far as I know the Hive2Main class is connecting to Beeline to run the Hive 
script. When connecting to Beeline via the command line I either pass the –n 
<username> argument to it (which isn’t possible in the Hive2 action because of 
the filtering of this argument) or I get prompted for my username and password 
when running !connect <jdbc-url> inside beeline. When using the anonymous user 
I don’t have the permissions to access the tables.

 

How can I pass the username and password to the Hive2 action to Beeline in the 
workflow required for connecting to the tables? Thanks for your help!

 

Jan

Reply via email to