Flume
  1. Flume
  2. FLUME-1179

flume-ng script silently fails if HADOOP_HOME isn't absolute

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: v1.1.0
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      Running bin/flume-ng fails silently if you specify HADOOP_HOME as a relative path (and you're using the HDFS sink). After configuration, the agent just blocks. It has something to do with the way the path is resolved. Very strange. I don't have time to debug right now, but I didn't want to lose this.

        Activity

        Hide
        Hari Shreedharan added a comment -

        I have seen this happen in other cases too. Basically if it cannot find the hadoop jar, when Class.forName() tries to create the class object for a class which has members which are from the hadoop jar, a NoClassDefFoundError is thrown(Class.forName throws a NoClassDefFoundError if it cant find the class for something defined inside a class it is trying to create the class object for - it throws a ClassNotFoundException if it can't find the class whose class object it is trying to load) . If you run it in a debugger, you can see that this causes the code to jump to the finally block in PropertiesFileConfigurationProvider#load(), and exits the function, and then nothing happens, not even the polling of the configuration file.

        This happens if anything that has a hadoop supplied class's object inside another class and the hadoop jar isn't in class path or can't be found. RecoverableMemoryChannel is an example - take a look at FLUME-1137.

        Show
        Hari Shreedharan added a comment - I have seen this happen in other cases too. Basically if it cannot find the hadoop jar, when Class.forName() tries to create the class object for a class which has members which are from the hadoop jar, a NoClassDefFoundError is thrown(Class.forName throws a NoClassDefFoundError if it cant find the class for something defined inside a class it is trying to create the class object for - it throws a ClassNotFoundException if it can't find the class whose class object it is trying to load) . If you run it in a debugger, you can see that this causes the code to jump to the finally block in PropertiesFileConfigurationProvider#load(), and exits the function, and then nothing happens, not even the polling of the configuration file. This happens if anything that has a hadoop supplied class's object inside another class and the hadoop jar isn't in class path or can't be found. RecoverableMemoryChannel is an example - take a look at FLUME-1137 .

          People

          • Assignee:
            Unassigned
            Reporter:
            E. Sammer
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:

              Development