Uploaded image for project: 'Oozie'
  1. Oozie
  2. OOZIE-2380

Oozie Hive action failed with wrong tmp path

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 4.2.0
    • Fix Version/s: 4.3.0
    • Component/s: core
    • Labels:

      Description

      Hive action with command "show tables" or "show databases" failed

      22257 [uber-SubtaskRunner] ERROR org.apache.hadoop.hive.ql.Driver  - FAILED: IllegalArgumentException java.net.URISyntaxException: Relative path in absolute URI: file:./tmp/mapr/b79b1ef5-c8a4-4da9-a307-b4f9045c7bb9/hive_2015-10-01_11-30$
      java.lang.IllegalArgumentException: java.net.URISyntaxException: Relative path in absolute URI: file:./tmp/mapr/b79b1ef5-c8a4-4da9-a307-b4f9045c7bb9/hive_2015-10-01_11-30-46_978_7012892802177357645-1
              at org.apache.hadoop.fs.Path.initialize(Path.java:217)
              at org.apache.hadoop.fs.Path.<init>(Path.java:208)
              at org.apache.hadoop.hive.ql.Context.getScratchDir(Context.java:284)
              at org.apache.hadoop.hive.ql.Context.getLocalScratchDir(Context.java:319)
              at org.apache.hadoop.hive.ql.Context.getLocalTmpPath(Context.java:414)
              at org.apache.hadoop.hive.ql.parse.DDLSemanticAnalyzer.analyzeInternal(DDLSemanticAnalyzer.java:337)
              at org.apache.hadoop.hive.ql.parse.BaseSemanticAnalyzer.analyze(BaseSemanticAnalyzer.java:227)
              at org.apache.hadoop.hive.ql.Driver.compile(Driver.java:424)
              at org.apache.hadoop.hive.ql.Driver.compile(Driver.java:308)
              at org.apache.hadoop.hive.ql.Driver.compileInternal(Driver.java:1122)
              at org.apache.hadoop.hive.ql.Driver.runInternal(Driver.java:1170)
              at org.apache.hadoop.hive.ql.Driver.run(Driver.java:1059)
              at org.apache.hadoop.hive.ql.Driver.run(Driver.java:1049)
              at org.apache.hadoop.hive.cli.CliDriver.processLocalCmd(CliDriver.java:213)
              at org.apache.hadoop.hive.cli.CliDriver.processCmd(CliDriver.java:165)
              at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:376)
              at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:311)
              at org.apache.hadoop.hive.cli.CliDriver.processReader(CliDriver.java:409)
              at org.apache.hadoop.hive.cli.CliDriver.processFile(CliDriver.java:425)
              at org.apache.hadoop.hive.cli.CliDriver.executeDriver(CliDriver.java:714)
              at org.apache.hadoop.hive.cli.CliDriver.run(CliDriver.java:681)
              at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:621)
              at org.apache.oozie.action.hadoop.HiveMain.runHive(HiveMain.java:306)
              at org.apache.oozie.action.hadoop.HiveMain.run(HiveMain.java:290)
              at org.apache.oozie.action.hadoop.LauncherMain.run(LauncherMain.java:47)
              at org.apache.oozie.action.hadoop.HiveMain.main(HiveMain.java:68)
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
              at java.lang.reflect.Method.invoke(Method.java:606)
              at org.apache.oozie.action.hadoop.LauncherMapper.map(LauncherMapper.java:230)
              at org.apache.hadoop.mapred.MapRunner.run(MapRunner.java:54)
              at org.apache.hadoop.mapred.MapTask.runOldMapper(MapTask.java:458)
              at org.apache.hadoop.mapred.MapTask.run(MapTask.java:348)
              at org.apache.hadoop.mapred.LocalContainerLauncher$EventHandler.runSubtask(LocalContainerLauncher.java:370)
              at org.apache.hadoop.mapred.LocalContainerLauncher$EventHandler.runTask(LocalContainerLauncher.java:295)
              at org.apache.hadoop.mapred.LocalContainerLauncher$EventHandler.access$200(LocalContainerLauncher.java:181)
              at org.apache.hadoop.mapred.LocalContainerLauncher$EventHandler$1.run(LocalContainerLauncher.java:224)
              at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
              at java.util.concurrent.FutureTask.run(FutureTask.java:262)
              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
              at java.lang.Thread.run(Thread.java:745)
      Caused by: java.net.URISyntaxException: Relative path in absolute URI: file:./tmp/mapr/b79b1ef5-c8a4-4da9-a307-b4f9045c7bb9/hive_2015-10-01_11-30-46_978_7012892802177357645-1
              at java.net.URI.checkPath(URI.java:1804)
              at java.net.URI.<init>(URI.java:752)
              at org.apache.hadoop.fs.Path.initialize(Path.java:214)
              ... 42 more
      
      22257 [uber-SubtaskRunner] INFO  org.apache.hadoop.hive.ql.log.PerfLogger  - </PERFLOG method=compile start=1443688246930 end=1443688247907 duration=977 from=org.apache.hadoop.hive.ql.Driver>
      
      1. OOZIE-2380-2.patch
        1 kB
        Sergey Svinarchuk
      2. OOZIE-2380-1.patch
        0.9 kB
        Sergey Svinarchuk

        Issue Links

          Activity

          Hide
          rkanter Robert Kanter added a comment -

          Closing issue; Oozie 4.3.0 is released.

          Show
          rkanter Robert Kanter added a comment - Closing issue; Oozie 4.3.0 is released.
          Hide
          vipul0036vipul@gmail.com Vipul singhal added a comment -

          i am trying to create table from union of two tables. its working well in hive console but giving error while i run it through oozie.

          *query is:*
          CREATE TABLE reconcile_table AS
          SELECT t1.* FROM
          (SELECT * FROM base_table
          UNION ALL
          SELECT * FROM incremental_table) t1
          JOIN
          (SELECT EMPNO, max(modified_date) max_modified FROM
          (SELECT * FROM base_table
          UNION ALL
          SELECT * FROM incremental_table) t2
          GROUP BY EMPNO) s
          ON t1.EMPNO = s.EMPNO AND t1.modified_date = s.max_modified;

          *and error is :*

          ERROR org.apache.hadoop.hive.ql.Driver - FAILED: IllegalArgumentException java.net.URISyntaxException: Relative path in absolute URI: file:./tmp/yarn/1c052ddc-1fff-48d0-8eec-a0581fe1f5e4/hive_2016-04-20_10-25-36_116_4089571356350445156-1
          java.lang.IllegalArgumentException: java.net.URISyntaxException: Relative path in absolute URI: file:./tmp/yarn/1c052ddc-1fff-48d0-8eec-a0581fe1f5e4/hive_2016-04-20_10-25-36_116_4089571356350445156-1
          at org.apache.hadoop.fs.Path.initialize(Path.java:206)

          Please tell me if u have any idea. Thanks in advance.

          Show
          vipul0036vipul@gmail.com Vipul singhal added a comment - i am trying to create table from union of two tables. its working well in hive console but giving error while i run it through oozie. * query is: * CREATE TABLE reconcile_table AS SELECT t1.* FROM (SELECT * FROM base_table UNION ALL SELECT * FROM incremental_table) t1 JOIN (SELECT EMPNO, max(modified_date) max_modified FROM (SELECT * FROM base_table UNION ALL SELECT * FROM incremental_table) t2 GROUP BY EMPNO) s ON t1.EMPNO = s.EMPNO AND t1.modified_date = s.max_modified; * and error is : * ERROR org.apache.hadoop.hive.ql.Driver - FAILED: IllegalArgumentException java.net.URISyntaxException: Relative path in absolute URI: file:./tmp/yarn/1c052ddc-1fff-48d0-8eec-a0581fe1f5e4/hive_2016-04-20_10-25-36_116_4089571356350445156-1 java.lang.IllegalArgumentException: java.net.URISyntaxException: Relative path in absolute URI: file:./tmp/yarn/1c052ddc-1fff-48d0-8eec-a0581fe1f5e4/hive_2016-04-20_10-25-36_116_4089571356350445156-1 at org.apache.hadoop.fs.Path.initialize(Path.java:206) Please tell me if u have any idea. Thanks in advance.
          Hide
          schitale Sachin added a comment -

          Hey Guys,
          I'm facing similar kind of issue, I'm running hive scripts in parallel (fork-join) using oozie but it fails after sometime with following exception

          80329 [uber-SubtaskRunner] ERROR org.apache.hadoop.hive.ql.Driver - FAILED: IllegalArgumentException java.net.URISyntaxException: Relative path in absolute URI: file:./tmp/yarn/73350afb-eaeb-4ffd-870f-f372529d2c43/hive_2016-02-07_19-41-46_786_3874484651830511681-1
          java.lang.IllegalArgumentException: java.net.URISyntaxException: Relative path in absolute URI: file:./tmp/yarn/73350afb-eaeb-4ffd-870f-f372529d2c43/hive_2016-02-07_19-41-46_786_3874484651830511681-1
          at org.apache.hadoop.fs.Path.initialize(Path.java:206)

          Can you please help me to resolve this by updating xml properties.

          Thanks!

          Show
          schitale Sachin added a comment - Hey Guys, I'm facing similar kind of issue, I'm running hive scripts in parallel (fork-join) using oozie but it fails after sometime with following exception 80329 [uber-SubtaskRunner] ERROR org.apache.hadoop.hive.ql.Driver - FAILED: IllegalArgumentException java.net.URISyntaxException: Relative path in absolute URI: file:./tmp/yarn/73350afb-eaeb-4ffd-870f-f372529d2c43/hive_2016-02-07_19-41-46_786_3874484651830511681-1 java.lang.IllegalArgumentException: java.net.URISyntaxException: Relative path in absolute URI: file:./tmp/yarn/73350afb-eaeb-4ffd-870f-f372529d2c43/hive_2016-02-07_19-41-46_786_3874484651830511681-1 at org.apache.hadoop.fs.Path.initialize(Path.java:206) Can you please help me to resolve this by updating xml properties. Thanks!
          Hide
          rohini Rohini Palaniswamy added a comment -

          I will open a separate jira to make it configurable for Oozie to set java.io.tmpdir for AMs.

          Created OOZIE-2424 for that.

          Show
          rohini Rohini Palaniswamy added a comment - I will open a separate jira to make it configurable for Oozie to set java.io.tmpdir for AMs. Created OOZIE-2424 for that.
          Hide
          rkanter Robert Kanter added a comment -

          That's a good idea too.

          Show
          rkanter Robert Kanter added a comment - That's a good idea too.
          Hide
          rkanter Robert Kanter added a comment -

          Thanks Sergey Svinarchuk. Committed to trunk!

          Show
          rkanter Robert Kanter added a comment - Thanks Sergey Svinarchuk . Committed to trunk!
          Hide
          rkanter Robert Kanter added a comment -

          Oh, you're right; I missed that

          Will commit shortly.

          Show
          rkanter Robert Kanter added a comment - Oh, you're right; I missed that Will commit shortly.
          Hide
          rohini Rohini Palaniswamy added a comment -

          +1 on OOZIE-2380-2.patch. Rohini Palaniswamy, do you agree?

          Yes. The patch was based on my comment. I will open a separate jira to make it configurable for Oozie to set java.io.tmpdir for AMs.

          Show
          rohini Rohini Palaniswamy added a comment - +1 on OOZIE-2380 -2.patch. Rohini Palaniswamy, do you agree? Yes. The patch was based on my comment. I will open a separate jira to make it configurable for Oozie to set java.io.tmpdir for AMs.
          Hide
          hadoopqa Hadoop QA added a comment -

          Testing JIRA OOZIE-2380

          Cleaning local git workspace

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

          +1 PATCH_APPLIES
          +1 CLEAN
          -1 RAW_PATCH_ANALYSIS
          . +1 the patch does not introduce any @author tags
          . +1 the patch does not introduce any tabs
          . +1 the patch does not introduce any trailing spaces
          . +1 the patch does not introduce any line longer than 132
          . -1 the patch does not add/modify any testcase
          +1 RAT
          . +1 the patch does not seem to introduce new RAT warnings
          +1 JAVADOC
          . +1 the patch does not seem to introduce new Javadoc warnings
          +1 COMPILE
          . +1 HEAD compiles
          . +1 patch compiles
          . +1 the patch does not seem to introduce new javac warnings
          +1 BACKWARDS_COMPATIBILITY
          . +1 the patch does not change any JPA Entity/Colum/Basic/Lob/Transient annotations
          . +1 the patch does not modify JPA files
          -1 TESTS
          . Tests run: 1703
          . Tests failed: 4
          . Tests errors: 0

          . The patch failed the following testcases:

          . testSamplers(org.apache.oozie.util.TestMetricsInstrumentation)
          . testBundleStatusTransitWithLock(org.apache.oozie.service.TestStatusTransitService)
          . testForNoDuplicates(org.apache.oozie.event.TestEventGeneration)
          . testCoordMaterializeTriggerService3(org.apache.oozie.service.TestCoordMaterializeTriggerService)

          +1 DISTRO
          . +1 distro tarball builds with the patch

          ----------------------------
          -1 Overall result, please check the reported -1(s)

          The full output of the test-patch run is available at

          . https://builds.apache.org/job/oozie-trunk-precommit-build/2687/

          Show
          hadoopqa Hadoop QA added a comment - Testing JIRA OOZIE-2380 Cleaning local git workspace ---------------------------- +1 PATCH_APPLIES +1 CLEAN -1 RAW_PATCH_ANALYSIS . +1 the patch does not introduce any @author tags . +1 the patch does not introduce any tabs . +1 the patch does not introduce any trailing spaces . +1 the patch does not introduce any line longer than 132 . -1 the patch does not add/modify any testcase +1 RAT . +1 the patch does not seem to introduce new RAT warnings +1 JAVADOC . +1 the patch does not seem to introduce new Javadoc warnings +1 COMPILE . +1 HEAD compiles . +1 patch compiles . +1 the patch does not seem to introduce new javac warnings +1 BACKWARDS_COMPATIBILITY . +1 the patch does not change any JPA Entity/Colum/Basic/Lob/Transient annotations . +1 the patch does not modify JPA files -1 TESTS . Tests run: 1703 . Tests failed: 4 . Tests errors: 0 . The patch failed the following testcases: . testSamplers(org.apache.oozie.util.TestMetricsInstrumentation) . testBundleStatusTransitWithLock(org.apache.oozie.service.TestStatusTransitService) . testForNoDuplicates(org.apache.oozie.event.TestEventGeneration) . testCoordMaterializeTriggerService3(org.apache.oozie.service.TestCoordMaterializeTriggerService) +1 DISTRO . +1 distro tarball builds with the patch ---------------------------- -1 Overall result, please check the reported -1(s) The full output of the test-patch run is available at . https://builds.apache.org/job/oozie-trunk-precommit-build/2687/
          Hide
          rkanter Robert Kanter added a comment -

          +1 on OOZIE-2380-2.patch. Rohini Palaniswamy, do you agree?

          I've also manually kicked off Jenkins, it had some git error.

          Show
          rkanter Robert Kanter added a comment - +1 on OOZIE-2380 -2.patch. Rohini Palaniswamy , do you agree? I've also manually kicked off Jenkins, it had some git error.
          Hide
          rkanter Robert Kanter added a comment -

          I think Hadoop 2.6.x is pretty popular, but I'm not sure. I like Sergey Svinarchuk's -2 patch, which sets some hive properties instead.

          Show
          rkanter Robert Kanter added a comment - I think Hadoop 2.6.x is pretty popular, but I'm not sure. I like Sergey Svinarchuk 's -2 patch, which sets some hive properties instead.
          Hide
          vaifer Sergey Svinarchuk added a comment -

          The best fix for this would be to set to hive.exec.local.scratchdir in HiveMain.java to an absolute path instead of it going to java.io.tmpdir.

          This fix works fine for all Hive query. I attached patch with this changes

          Show
          vaifer Sergey Svinarchuk added a comment - The best fix for this would be to set to hive.exec.local.scratchdir in HiveMain.java to an absolute path instead of it going to java.io.tmpdir. This fix works fine for all Hive query. I attached patch with this changes
          Hide
          rohini Rohini Palaniswamy added a comment -

          I created an internal jira for our hadoop team leaving it to them to create the Apache one. Will create an Apache one as well and link it to that jira.

          Found that they already filed the jira and fixed it in Hadoop 2.7.2. It is MAPREDUCE-6472.

          So it would also be good to make it as a server level configurable setting in Oozie to set java.io.tmpdir to ./tmp instead of doing it always. It can either

          • be false by default and folks having versions < Hadoop 2.7.2 can turn it on.
          • be true by default and folks having Hadoop 2.7.2+ can turn it off. Can make it false by default in future release of Oozie after Hadoop 2.7 is widely adopted.

          Robert Kanter, thoughts? I don't have a preference for either. Do you have any idea on the general hadoop 2.x version in wide adoption?

          Show
          rohini Rohini Palaniswamy added a comment - I created an internal jira for our hadoop team leaving it to them to create the Apache one. Will create an Apache one as well and link it to that jira. Found that they already filed the jira and fixed it in Hadoop 2.7.2. It is MAPREDUCE-6472 . So it would also be good to make it as a server level configurable setting in Oozie to set java.io.tmpdir to ./tmp instead of doing it always. It can either be false by default and folks having versions < Hadoop 2.7.2 can turn it on. be true by default and folks having Hadoop 2.7.2+ can turn it off. Can make it false by default in future release of Oozie after Hadoop 2.7 is widely adopted. Robert Kanter , thoughts? I don't have a preference for either. Do you have any idea on the general hadoop 2.x version in wide adoption?
          Hide
          rohini Rohini Palaniswamy added a comment -

          Sergey Svinarchuk,

          I don't see this exception in other queries (only show tables and show databases)

          That is good to know as users usually don't put show databases or show tables in their hive action scripts. So impact is minimal.

          The best fix for this would be to set to hive.exec.local.scratchdir in HiveMain.java to an absolute path instead of it going to java.io.tmpdir.

          LOCALSCRATCHDIR("hive.exec.local.scratchdir", System.getProperty("java.io.tmpdir") + File.separator + System.getProperty("user.name")),

          Currently we already do hiveConf.set("hive.querylog.location", "./hivelogs");

          String pwd = new File("").getCanonicalPath();
          hiveConf.set("hive.querylog.location", pwd + File.separator + "hivetmp" + File.separator + "querylog");
          hiveConf.set("hive.exec.local.scratchdir", pwd + File.separator + "hivetmp" + File.separator + "scratchdir");
          
          Show
          rohini Rohini Palaniswamy added a comment - Sergey Svinarchuk , I don't see this exception in other queries (only show tables and show databases) That is good to know as users usually don't put show databases or show tables in their hive action scripts. So impact is minimal. The best fix for this would be to set to hive.exec.local.scratchdir in HiveMain.java to an absolute path instead of it going to java.io.tmpdir. LOCALSCRATCHDIR("hive.exec.local.scratchdir", System.getProperty("java.io.tmpdir") + File.separator + System.getProperty("user.name")), Currently we already do hiveConf.set("hive.querylog.location", "./hivelogs"); String pwd = new File("").getCanonicalPath(); hiveConf.set( "hive.querylog.location" , pwd + File.separator + "hivetmp" + File.separator + "querylog" ); hiveConf.set( "hive.exec.local.scratchdir" , pwd + File.separator + "hivetmp" + File.separator + "scratchdir" );
          Hide
          vaifer Sergey Svinarchuk added a comment -

          I found this bug when run Oozie examples in Hue and I don't see this exception in other queries (only show tables and show databases)

          If disable uber mode in Oozie, all hive action passed.
          <property>
          <name>oozie.action.launcher.mapreduce.job.ubertask.enable</name>
          <value>false</value>
          </property>

          Show
          vaifer Sergey Svinarchuk added a comment - I found this bug when run Oozie examples in Hue and I don't see this exception in other queries (only show tables and show databases) If disable uber mode in Oozie, all hive action passed. <property> <name>oozie.action.launcher.mapreduce.job.ubertask.enable</name> <value>false</value> </property>
          Hide
          rohini Rohini Palaniswamy added a comment -

          -Djava.io.tmpdir should be set to ./tmp so that whatever a task does is cleaned up after it is done. Mapreduce already sets it for all tasks, but it does not do it for the AM. It should be fixed in mapreduce for the AM as well. I created an internal jira for our hadoop team leaving it to them to create the Apache one. Will create an Apache one as well and link it to that jira. When we started running launcher in uber mode, java.io.tmpdir was not referring to ./tmp anymore like the map task and that caused problem. We put the fix in Oozie first, as getting it fixed in hadoop will take longer and will also work with older versions of hadoop. Since it is already set for tasks by mapreduce, OOZIE-2260 (followup for OOZIE-2209) set -Djava.io.tmpdir=./tmp only for the launcher AMs.

          Setting it to System.getProperty("user.dir") + "/tmp" is not good as

          • many cluster deployments will not have home directory for users on the task nodes and it will break them
          • There is no cleanup which will accumulate over time and make the nodes go out of disk space

          Surprising that none of our users have reported this issue. May be it is because they are not using show tables or show databases command in the script.

          Sergey Svinarchuk,
          This issue does not happen with any other command in hive action right? Only show tables and show databases? Mapreduce sets it to -Djava.io.tmpdir=$

          {PWD}/tmp for tasks, so most likely it will run fine as ${PWD}

          will expand to an absolute path. We could not do that in Oozie as it will expand to server's $

          {PWD}

          and so had to do ./tmp instead. Can you test once with uber mode disabled for the particular hive action and see if that works?

          Show
          rohini Rohini Palaniswamy added a comment - -Djava.io.tmpdir should be set to ./tmp so that whatever a task does is cleaned up after it is done. Mapreduce already sets it for all tasks, but it does not do it for the AM. It should be fixed in mapreduce for the AM as well. I created an internal jira for our hadoop team leaving it to them to create the Apache one. Will create an Apache one as well and link it to that jira. When we started running launcher in uber mode, java.io.tmpdir was not referring to ./tmp anymore like the map task and that caused problem. We put the fix in Oozie first, as getting it fixed in hadoop will take longer and will also work with older versions of hadoop. Since it is already set for tasks by mapreduce, OOZIE-2260 (followup for OOZIE-2209 ) set -Djava.io.tmpdir=./tmp only for the launcher AMs. Setting it to System.getProperty("user.dir") + "/tmp" is not good as many cluster deployments will not have home directory for users on the task nodes and it will break them There is no cleanup which will accumulate over time and make the nodes go out of disk space Surprising that none of our users have reported this issue. May be it is because they are not using show tables or show databases command in the script. Sergey Svinarchuk , This issue does not happen with any other command in hive action right? Only show tables and show databases? Mapreduce sets it to -Djava.io.tmpdir=$ {PWD}/tmp for tasks, so most likely it will run fine as ${PWD} will expand to an absolute path. We could not do that in Oozie as it will expand to server's $ {PWD} and so had to do ./tmp instead. Can you test once with uber mode disabled for the particular hive action and see if that works?
          Hide
          vaifer Sergey Svinarchuk added a comment -

          Yes, I already see that Oozie has permission issue if uses System.getProperty("user.dir"), but set temporary folder as "./tmp" also has exeption.
          Maybe will be better revert OOZIE-2209 and resolve issue with free space on Pig launcher side.

          Show
          vaifer Sergey Svinarchuk added a comment - Yes, I already see that Oozie has permission issue if uses System.getProperty("user.dir"), but set temporary folder as "./tmp" also has exeption. Maybe will be better revert OOZIE-2209 and resolve issue with free space on Pig launcher side.
          Hide
          rkanter Robert Kanter added a comment -

          Oh wait, it won't be possible to resolve ./tmp here either. This is in the Oozie Server, but we're interested in the MR AM's working dir. Any ideas Rohini Palaniswamy? Maybe we can set this on the launcher side or something?

          Show
          rkanter Robert Kanter added a comment - Oh wait, it won't be possible to resolve ./tmp here either. This is in the Oozie Server, but we're interested in the MR AM's working dir. Any ideas Rohini Palaniswamy ? Maybe we can set this on the launcher side or something?
          Hide
          rkanter Robert Kanter added a comment -

          Thanks for posting a patch for this Sergey Svinarchuk. However, I think we should have the code resolve ./tmp to an absolute path instead of using /home/<username>/tmp (or the equivalent). For one thing, System.getProperty("user.dir") gets resolved in the Oozie Server, so it would be the Oozie Server user's home directory on that host; but it's actually used by the MR AM on a potentially different host, likely run by a different user, so this could run into permissions issues or other problems. Also, based on the information in OOZIE-2209, which added the java.io.tmp stuff, the NM will take care of cleaning up ./tmp for us.

          Show
          rkanter Robert Kanter added a comment - Thanks for posting a patch for this Sergey Svinarchuk . However, I think we should have the code resolve ./tmp to an absolute path instead of using /home/<username>/tmp (or the equivalent). For one thing, System.getProperty("user.dir") gets resolved in the Oozie Server, so it would be the Oozie Server user's home directory on that host; but it's actually used by the MR AM on a potentially different host, likely run by a different user, so this could run into permissions issues or other problems. Also, based on the information in OOZIE-2209 , which added the java.io.tmp stuff, the NM will take care of cleaning up ./tmp for us.
          Hide
          hadoopqa Hadoop QA added a comment -

          Testing JIRA OOZIE-2380

          Cleaning local git workspace

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

          +1 PATCH_APPLIES
          +1 CLEAN
          -1 RAW_PATCH_ANALYSIS
          . +1 the patch does not introduce any @author tags
          . +1 the patch does not introduce any tabs
          . +1 the patch does not introduce any trailing spaces
          . +1 the patch does not introduce any line longer than 132
          . -1 the patch does not add/modify any testcase
          +1 RAT
          . +1 the patch does not seem to introduce new RAT warnings
          +1 JAVADOC
          . +1 the patch does not seem to introduce new Javadoc warnings
          +1 COMPILE
          . +1 HEAD compiles
          . +1 patch compiles
          . +1 the patch does not seem to introduce new javac warnings
          +1 BACKWARDS_COMPATIBILITY
          . +1 the patch does not change any JPA Entity/Colum/Basic/Lob/Transient annotations
          . +1 the patch does not modify JPA files
          -1 TESTS
          . Tests run: 1702
          . Tests failed: 5
          . Tests errors: 0

          . The patch failed the following testcases:

          . testForNoDuplicates(org.apache.oozie.event.TestEventGeneration)
          . testSamplers(org.apache.oozie.util.TestMetricsInstrumentation)
          . testUpdateConfForUberMode(org.apache.oozie.action.hadoop.TestJavaActionExecutor)
          . testUpdateConfForUberModeForJavaOpts(org.apache.oozie.action.hadoop.TestJavaActionExecutor)
          . testUpdateSLA(org.apache.oozie.sla.TestSLAService)

          +1 DISTRO
          . +1 distro tarball builds with the patch

          ----------------------------
          -1 Overall result, please check the reported -1(s)

          The full output of the test-patch run is available at

          . https://builds.apache.org/job/oozie-trunk-precommit-build/2624/

          Show
          hadoopqa Hadoop QA added a comment - Testing JIRA OOZIE-2380 Cleaning local git workspace ---------------------------- +1 PATCH_APPLIES +1 CLEAN -1 RAW_PATCH_ANALYSIS . +1 the patch does not introduce any @author tags . +1 the patch does not introduce any tabs . +1 the patch does not introduce any trailing spaces . +1 the patch does not introduce any line longer than 132 . -1 the patch does not add/modify any testcase +1 RAT . +1 the patch does not seem to introduce new RAT warnings +1 JAVADOC . +1 the patch does not seem to introduce new Javadoc warnings +1 COMPILE . +1 HEAD compiles . +1 patch compiles . +1 the patch does not seem to introduce new javac warnings +1 BACKWARDS_COMPATIBILITY . +1 the patch does not change any JPA Entity/Colum/Basic/Lob/Transient annotations . +1 the patch does not modify JPA files -1 TESTS . Tests run: 1702 . Tests failed: 5 . Tests errors: 0 . The patch failed the following testcases: . testForNoDuplicates(org.apache.oozie.event.TestEventGeneration) . testSamplers(org.apache.oozie.util.TestMetricsInstrumentation) . testUpdateConfForUberMode(org.apache.oozie.action.hadoop.TestJavaActionExecutor) . testUpdateConfForUberModeForJavaOpts(org.apache.oozie.action.hadoop.TestJavaActionExecutor) . testUpdateSLA(org.apache.oozie.sla.TestSLAService) +1 DISTRO . +1 distro tarball builds with the patch ---------------------------- -1 Overall result, please check the reported -1(s) The full output of the test-patch run is available at . https://builds.apache.org/job/oozie-trunk-precommit-build/2624/
          Hide
          laesunKim laesunK added a comment -

          4.1 version also has same issue

          Show
          laesunKim laesunK added a comment - 4.1 version also has same issue
          Hide
          ssvinarchuk Sergey Svinarchuk added a comment -

          Yes, this patch fix issue

          Show
          ssvinarchuk Sergey Svinarchuk added a comment - Yes, this patch fix issue
          Hide
          rxue Rui Xue added a comment -

          I suffered from the same error with "show databases" sql in hive action. So does it mean that I have to add this patch and build the Oozie again?

          Show
          rxue Rui Xue added a comment - I suffered from the same error with "show databases" sql in hive action. So does it mean that I have to add this patch and build the Oozie again?
          Hide
          hadoopqa Hadoop QA added a comment -

          Testing JIRA OOZIE-2380

          Cleaning local git workspace

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

          +1 PATCH_APPLIES
          +1 CLEAN
          -1 RAW_PATCH_ANALYSIS
          . +1 the patch does not introduce any @author tags
          . +1 the patch does not introduce any tabs
          . +1 the patch does not introduce any trailing spaces
          . +1 the patch does not introduce any line longer than 132
          . -1 the patch does not add/modify any testcase
          +1 RAT
          . +1 the patch does not seem to introduce new RAT warnings
          +1 JAVADOC
          . +1 the patch does not seem to introduce new Javadoc warnings
          +1 COMPILE
          . +1 HEAD compiles
          . +1 patch compiles
          . +1 the patch does not seem to introduce new javac warnings
          +1 BACKWARDS_COMPATIBILITY
          . +1 the patch does not change any JPA Entity/Colum/Basic/Lob/Transient annotations
          . +1 the patch does not modify JPA files
          -1 TESTS - patch does not compile, cannot run testcases
          +1 DISTRO
          . +1 distro tarball builds with the patch

          ----------------------------
          -1 Overall result, please check the reported -1(s)

          The full output of the test-patch run is available at

          . https://builds.apache.org/job/oozie-trunk-precommit-build/2564/

          Show
          hadoopqa Hadoop QA added a comment - Testing JIRA OOZIE-2380 Cleaning local git workspace ---------------------------- +1 PATCH_APPLIES +1 CLEAN -1 RAW_PATCH_ANALYSIS . +1 the patch does not introduce any @author tags . +1 the patch does not introduce any tabs . +1 the patch does not introduce any trailing spaces . +1 the patch does not introduce any line longer than 132 . -1 the patch does not add/modify any testcase +1 RAT . +1 the patch does not seem to introduce new RAT warnings +1 JAVADOC . +1 the patch does not seem to introduce new Javadoc warnings +1 COMPILE . +1 HEAD compiles . +1 patch compiles . +1 the patch does not seem to introduce new javac warnings +1 BACKWARDS_COMPATIBILITY . +1 the patch does not change any JPA Entity/Colum/Basic/Lob/Transient annotations . +1 the patch does not modify JPA files -1 TESTS - patch does not compile, cannot run testcases +1 DISTRO . +1 distro tarball builds with the patch ---------------------------- -1 Overall result, please check the reported -1(s) The full output of the test-patch run is available at . https://builds.apache.org/job/oozie-trunk-precommit-build/2564/
          Hide
          vaifer Sergey Svinarchuk added a comment -

          For Hive action with these commands need absolute path to tmp directory
          I attached patch with fix.

          Show
          vaifer Sergey Svinarchuk added a comment - For Hive action with these commands need absolute path to tmp directory I attached patch with fix.

            People

            • Assignee:
              vaifer Sergey Svinarchuk
              Reporter:
              vaifer Sergey Svinarchuk
            • Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development