Hadoop Common
  1. Hadoop Common
  2. HADOOP-6283

The exception meessage in FileUtil$HardLink.getLinkCount(..) is not clear

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.21.0
    • Component/s: fs
    • Labels:
      None
    • Hadoop Flags:
      Reviewed

      Description

      When a file is not found, FileUtil$HardLink.getLinkCount(..) shows the following error message.

      java.lang.NumberFormatException: For input string: ""
      	at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
      	at java.lang.Integer.parseInt(Integer.java:470)
      	at java.lang.Integer.parseInt(Integer.java:499)
      	at org.apache.hadoop.fs.FileUtil$HardLink.getLinkCount(FileUtil.java:663)
      	at org.apache.hadoop.hdfs.server.datanode.ReplicaInfo.detachBlock(ReplicaInfo.java:209)
      	...
      stat: cannot stat `/home/tsz/hadoop/hdfs/h265/build/test/data/dfs/data/data3/current/finalized/blk_-94418387820168072_1001.meta':
       No such file or directory on file:/home/tsz/hadoop/hdfs/h265/build/test/data/dfs/data/data3/current/finalized/blk_-94418387820168072_1001.meta
      

      It looks like that there was a uncaught NumberFormatException.

      1. c6283_20091007.patch
        3 kB
        Tsz Wo Nicholas Sze
      2. c6283_20090923.patch
        0.6 kB
        Tsz Wo Nicholas Sze

        Activity

        Tsz Wo Nicholas Sze created issue -
        Tsz Wo Nicholas Sze made changes -
        Field Original Value New Value
        Summary FileUtil$HardLink.getLinkCount(..) throws NumberFormatException The exception meessage in FileUtil$HardLink.getLinkCount(..) is not clear
        Description {noformat}
        java.lang.NumberFormatException: For input string: ""
        at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
        at java.lang.Integer.parseInt(Integer.java:470)
        at java.lang.Integer.parseInt(Integer.java:499)
        at org.apache.hadoop.fs.FileUtil$HardLink.getLinkCount(FileUtil.java:663)
        at org.apache.hadoop.hdfs.server.datanode.ReplicaInfo.detachBlock(ReplicaInfo.java:209)
        ...
        {noformat}
        When a file is not found, FileUtil$HardLink.getLinkCount(..) shows the following error message.
        {noformat}
        java.lang.NumberFormatException: For input string: ""
        at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
        at java.lang.Integer.parseInt(Integer.java:470)
        at java.lang.Integer.parseInt(Integer.java:499)
        at org.apache.hadoop.fs.FileUtil$HardLink.getLinkCount(FileUtil.java:663)
        at org.apache.hadoop.hdfs.server.datanode.ReplicaInfo.detachBlock(ReplicaInfo.java:209)
        ...
        stat: cannot stat `/home/tsz/hadoop/hdfs/h265/build/test/data/dfs/data/data3/current/finalized/blk_-94418387820168072_1001.meta': No such file or directory on file:/home/tsz/hadoop/hdfs/h265/build/test/data/dfs/data/data3/current/finalized/blk_-94418387820168072_1001.meta
        {noformat}
        It looks like that there was a uncaught NumberFormatException.
        Tsz Wo Nicholas Sze made changes -
        Priority Major [ 3 ] Minor [ 4 ]
        Description When a file is not found, FileUtil$HardLink.getLinkCount(..) shows the following error message.
        {noformat}
        java.lang.NumberFormatException: For input string: ""
        at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
        at java.lang.Integer.parseInt(Integer.java:470)
        at java.lang.Integer.parseInt(Integer.java:499)
        at org.apache.hadoop.fs.FileUtil$HardLink.getLinkCount(FileUtil.java:663)
        at org.apache.hadoop.hdfs.server.datanode.ReplicaInfo.detachBlock(ReplicaInfo.java:209)
        ...
        stat: cannot stat `/home/tsz/hadoop/hdfs/h265/build/test/data/dfs/data/data3/current/finalized/blk_-94418387820168072_1001.meta': No such file or directory on file:/home/tsz/hadoop/hdfs/h265/build/test/data/dfs/data/data3/current/finalized/blk_-94418387820168072_1001.meta
        {noformat}
        It looks like that there was a uncaught NumberFormatException.
        When a file is not found, FileUtil$HardLink.getLinkCount(..) shows the following error message.
        {noformat}
        java.lang.NumberFormatException: For input string: ""
        at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48)
        at java.lang.Integer.parseInt(Integer.java:470)
        at java.lang.Integer.parseInt(Integer.java:499)
        at org.apache.hadoop.fs.FileUtil$HardLink.getLinkCount(FileUtil.java:663)
        at org.apache.hadoop.hdfs.server.datanode.ReplicaInfo.detachBlock(ReplicaInfo.java:209)
        ...
        stat: cannot stat `/home/tsz/hadoop/hdfs/h265/build/test/data/dfs/data/data3/current/finalized/blk_-94418387820168072_1001.meta':
         No such file or directory on file:/home/tsz/hadoop/hdfs/h265/build/test/data/dfs/data/data3/current/finalized/blk_-94418387820168072_1001.meta
        {noformat}
        It looks like that there was a uncaught NumberFormatException.
        Tsz Wo Nicholas Sze made changes -
        Attachment c6283_20090923.patch [ 12420415 ]
        Tsz Wo Nicholas Sze made changes -
        Status Open [ 1 ] Patch Available [ 10002 ]
        Tsz Wo Nicholas Sze made changes -
        Attachment c6283_20091007.patch [ 12421555 ]
        Tsz Wo Nicholas Sze made changes -
        Status Patch Available [ 10002 ] Open [ 1 ]
        Tsz Wo Nicholas Sze made changes -
        Status Open [ 1 ] Patch Available [ 10002 ]
        Hadoop Flags [Reviewed]
        Assignee Tsz Wo (Nicholas), SZE [ szetszwo ]
        Tsz Wo Nicholas Sze made changes -
        Status Patch Available [ 10002 ] Resolved [ 5 ]
        Fix Version/s 0.22.0 [ 12314296 ]
        Resolution Fixed [ 1 ]
        Tom White made changes -
        Fix Version/s 0.21.0 [ 12313563 ]
        Fix Version/s 0.22.0 [ 12314296 ]
        Tom White made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Tsz Wo Nicholas Sze
            Reporter:
            Tsz Wo Nicholas Sze
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development