Uploaded image for project: 'Hadoop YARN'
  1. Hadoop YARN
  2. YARN-2640

TestDirectoryCollection.testCreateDirectories failed

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Duplicate
    • None
    • None
    • nodemanager
    • None

    Description

      When running test "mvn test -Dtest=TestDirectoryCollection", it failed:

      Running org.apache.hadoop.yarn.server.nodemanager.TestDirectoryCollection
      Tests run: 5, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 1.538 sec <<< FAILURE! - in org.apache.hadoop.yarn.server.nodemanager.TestDirectoryCollection
      testCreateDirectories(org.apache.hadoop.yarn.server.nodemanager.TestDirectoryCollection)  Time elapsed: 0.969 sec  <<< FAILURE!
      java.lang.AssertionError: local dir parent not created with proper permissions expected:<rwxr-xr-x> but was:<rwxrwxr-x>
      	at org.junit.Assert.fail(Assert.java:88)
      	at org.junit.Assert.failNotEquals(Assert.java:743)
      	at org.junit.Assert.assertEquals(Assert.java:118)
      	at org.apache.hadoop.yarn.server.nodemanager.TestDirectoryCollection.testCreateDirectories(TestDirectoryCollection.java:104)
      

      I found it was because testDiskSpaceUtilizationLimit ran before testCreateDirectories when running test, then directory "dirA" was created in test function testDiskSpaceUtilizationLimit. When testCreateDirectories tried to create "dirA" with specified permission, it found "dirA" has already been there and it did nothing.

      Attachments

        1. YARN-2640.patch
          3 kB
          Jun Gong
        2. YARN-2640.2.patch
          3 kB
          Jun Gong

        Issue Links

          Activity

            People

              hex108 Jun Gong
              hex108 Jun Gong
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: