Uploaded image for project: 'Hadoop HDFS'
  1. Hadoop HDFS
  2. HDFS-7947 Fix HDFS unit test failures on Windows
  3. HDFS-8309

Skip unit test using DataNodeTestUtils#injectDataDirFailure() on Windows

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 2.7.0
    • 2.8.0, 3.0.0-alpha1
    • test
    • None
    • Reviewed

    Description

      As Chris Nauroth noted in HDFS-7917 below, DataNodeTestUtils.injectDataDirFailure() won't work for Windows as rename will fail due to open handles on data node dir. This ticket is opened to skip these tests for Windows.

      Unfortunately, I just remembered that the rename isn't going to work on Windows. It typically doesn't allow you to rename a directory where there are open file handles anywhere in the sub-tree. We'd have to shutdown the DataNode before doing the rename and then start it up. By doing that, we'd be changing the meaning of the test from covering an online failure to covering a failure at DataNode startup, so I don't think we can make that change.

      Below are the two test cases that need to be fixed:

      1. TestDataNodeVolumeFailure#testFailedVolumeBeingRemovedFromDataNode
      2. TestDataNodeHotSwapVolumes.testDirectlyReloadAfterCheckDiskError

      Attachments

        1. HDFS-8309.00.patch
          4 kB
          Xiaoyu Yao

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            xyao Xiaoyu Yao
            xyao Xiaoyu Yao
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment