You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-issues@hadoop.apache.org by "Chris Nauroth (JIRA)" <ji...@apache.org> on 2014/04/11 08:17:14 UTC

[jira] [Commented] (HDFS-6234) TestDatanodeConfig#testMemlockLimit fails on Windows due to invalid file path.

    [ https://issues.apache.org/jira/browse/HDFS-6234?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13966274#comment-13966274 ] 

Chris Nauroth commented on HDFS-6234:
-------------------------------------

Here is the default for {{dfs.datanode.data.dir}}:

{code}
file://${hadoop.tmp.dir}/dfs/data
{code}

{{hadoop.tmp.dir}} will be a Windows file system path with back slashes.  The problem is that prepending "file://" in front of a Windows file system path does not necessarily yield a valid URI because of the back slashes.  The test fails with this exception:

{code}
java.lang.IllegalArgumentException: Failed to parse conf property dfs.datanode.data.dir: file://D:\w\hbk\hadoop-hdfs-project\hadoop-hdfs\target/test/dfs/data
	at java.io.WinNTFileSystem.canonicalize0(Native Method)
	at java.io.Win32FileSystem.canonicalize(Win32FileSystem.java:414)
	at java.io.File.getCanonicalPath(File.java:589)
	at java.io.File.getCanonicalFile(File.java:614)
	at org.apache.hadoop.hdfs.server.common.Util.fileAsURI(Util.java:73)
	at org.apache.hadoop.hdfs.server.common.Util.stringAsURI(Util.java:58)
	at org.apache.hadoop.hdfs.server.datanode.StorageLocation.parse(StorageLocation.java:94)
	at org.apache.hadoop.hdfs.server.datanode.DataNode.getStorageLocations(DataNode.java:1784)
	at org.apache.hadoop.hdfs.server.datanode.DataNode.instantiateDataNode(DataNode.java:1768)
	at org.apache.hadoop.hdfs.server.datanode.DataNode.createDataNode(DataNode.java:1812)
	at org.apache.hadoop.hdfs.server.datanode.DataNode.createDataNode(DataNode.java:1802)
	at org.apache.hadoop.hdfs.TestDatanodeConfig.testMemlockLimit(TestDatanodeConfig.java:133)
{code}


> TestDatanodeConfig#testMemlockLimit fails on Windows due to invalid file path.
> ------------------------------------------------------------------------------
>
>                 Key: HDFS-6234
>                 URL: https://issues.apache.org/jira/browse/HDFS-6234
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: datanode, test
>    Affects Versions: 3.0.0, 2.4.0
>            Reporter: Chris Nauroth
>            Assignee: Chris Nauroth
>            Priority: Trivial
>
> {{TestDatanodeConfig#testMemlockLimit}} fails to initialize a {{DataNode}} due to an invalid URI configured in {{dfs.datanode.data.dir}}.



--
This message was sent by Atlassian JIRA
(v6.2#6252)