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

race condition crashes "hadoop ls -R" when directories are moved/removed

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Not A Problem
    • 2.2.0
    • None
    • None

    Description

      This seems to be a rare race condition where we have a sequence of events like this:
      1. org.apache.hadoop.shell.Ls calls DFS#getFileStatus on directory D.
      2. someone deletes or moves directory D
      3. org.apache.hadoop.shell.Ls calls PathData#getDirectoryContents(D), which calls DFS#listStatus(D). This throws FileNotFoundException.
      4. ls command terminates with FNF

      Attachments

        1. HDFS-5546.1.patch
          1 kB
          Kousuke Saruta
        2. HDFS-5546.2.000.patch
          2 kB
          Lei (Eddy) Xu
        3. HDFS-5546.2.001.patch
          8 kB
          Lei (Eddy) Xu
        4. HDFS-5546.2.002.patch
          7 kB
          Lei (Eddy) Xu
        5. HDFS-5546.2.003.patch
          7 kB
          Lei (Eddy) Xu
        6. HDFS-5546.2.004.patch
          7 kB
          Lei (Eddy) Xu

        Activity

          People

            eddyxu Lei (Eddy) Xu
            cmccabe Colin McCabe
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: