Uploaded image for project: 'Hadoop HDFS'
  1. Hadoop HDFS
  2. HDFS-3808

fuse_dfs: postpone libhdfs intialization until after fork

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 2.0.2-alpha
    • Fix Version/s: 2.0.2-alpha
    • Component/s: fuse-dfs
    • Labels:
      None

      Description

      libhdfs may create threads or initialize internal JNI data structures when it is used. So we should be careful to daemonize() before initializing libhdfs, not after.

      Unfortunately, fuse_dfs is doing just this – initializing libhdfs in its main function, prior to calling fuse_main which does a daemonize.

      daemonize() does not preserve threads, because it is implemented by fork()}}ing and then continuing execution in the child and allowing the parent to {{exit().

        Attachments

        1. HDFS-3808.001.patch
          4 kB
          Colin P. McCabe
        2. HDFS-3808.002.patch
          5 kB
          Colin P. McCabe
        3. HDFS-3808.003.patch
          5 kB
          Colin P. McCabe

          Activity

            People

            • Assignee:
              cmccabe Colin P. McCabe
              Reporter:
              cmccabe Colin P. McCabe
            • Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: