Hue/oozie weirdness

26 views
Skip to first unread message

Guillaume

unread,
Jul 7, 2016, 9:40:39 AM7/7/16
to Hue-Users
Hi,

I have a weird issue with hue (I think).

I have a very simple hive query:

drop table if exists csv_dump;
create table csv_dump row format delimited fields terminated by ',' lines terminated by '\n' location '/user/oozie/export' as select * from sample;

- running this query in the hive editor works
- running this query as an oozie workflow command line works
- running this query command line with beeline works
- running this query via an oozie workflow from hive fails

Fail in that case means:
- drop and create are not run, or at least do not have any effect
- a prepare action in the workflow will be executed
- the hive2 step in the workflow still says succeeded
- a following step will be executed.

Now I did try with different users (oozie and ambari, adapting the location as relevant), with exactly the same success/failure cases.

I cannot find any relevant logs, except maybe from hue:

------------------------

Beeline command arguments :
             -u
             jdbc:hive2://ip-10-0-0-139.eu-west-1.compute.internal:10000/default
             -n
             oozie
             -p
             DUMMY
             -d
             org.apache.hive.jdbc.HiveDriver
             -f
             s.q
             -a
             delegationToken
             --hiveconf
             mapreduce.job.tags=oozie-e686d7aaef4a29c020059e150d36db98

Fetching child yarn jobs
tag id : oozie-e686d7aaef4a29c020059e150d36db98
Child yarn jobs are found - 
=================================================================

>>> Invoking Beeline command line now >>>

0: jdbc:hive2://ip-10-0-0-139.eu-west-1.compu> drop table if exists csv_dump; cr 
eate table csv_dump0 row format delimited fields terminated by ',' lines termina 
ted by '\n' location '/user/ambari/export' as select * from sample;

<<< Invocation of Beeline command completed <<<

 Hadoop Job IDs executed by Beeline: 


<<< Invocation of Main class completed <<<


Oozie Launcher, capturing output data:
=======================
#
#Thu Jul 07 13:12:39 UTC 2016
hadoopJobs=


=======================

Oozie Launcher, uploading action data to HDFS sequence file: hdfs://ip-10-0-0-139.eu-west-1.compute.internal:8020/user/oozie/oozie-oozi/0000011-160707062514560-oozie-oozi-W/hive2-f2c9--hive2/action-data.seq

Oozie Launcher ends

Where I see that beeline is started, but I do  not see any mapper allocated as I do command line.

Would anybody have any idea of what could go wrong?

Thanks,
Guillaume




Romain Rigaux

unread,
Jul 18, 2016, 11:20:32 AM7/18/16
to Guillaume, Hue-Users
Could you quick try with a bunch of \n in your script?

--
You received this message because you are subscribed to the Google Groups "Hue-Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hue-user+u...@cloudera.org.

Guillaume Roger | webpower

unread,
Jul 19, 2016, 3:06:21 AM7/19/16
to Romain Rigaux, Hue-Users
Amazing, this was indeed the issue. Adding a newline after each statement did fix the issue from hue. 
I would tend to consider this as a bug, but at least I now have an easy workaround.'

Thanks!
--
Guillaume Roger
Senior big data engineer & architect @ Webpower
Koolhovenstraat 1k, 3772 MT, Barneveld, Nederland
guillaume.roger@webpower.nl | +31 (0) 342 423 262

Romain Rigaux

unread,
Jul 25, 2016, 12:59:31 PM7/25/16
to Guillaume Roger | webpower, Hue-Users
This was probably edited in Windows and Oozie / beeline do not expect that (Hue does not touch the file)

Guillaume Roger | webpower

unread,
Jul 26, 2016, 1:29:24 AM7/26/16
to Romain Rigaux, Hue-Users
Weirdly enough no, I work exclusively under Linux, so there should not have been weird unexpected line endings.
Reply all
Reply to author
Forward
0 new messages