|
|
| Created: (HADOOP-1647)
DistributedFileSystem.getFileStatus()
fails for path "/" |
  United States |
2007-07-23 09:38:31 |
DistributedFileSystem.getFileStatus() fails for path
"/"
--------------------------------------------------------
Key: HADOOP-1647
URL: htt
ps://issues.apache.org/jira/browse/HADOOP-1647
Project: Hadoop
Issue Type: Bug
Components: dfs
Affects Versions: 0.15.0
Reporter: Enis Soztutar
Fix For: 0.15.0
DistributedFileSystem#getFileStatus throws the following
exception when invoked with new Path("/").
LocalFileSystem does not. The code to produce this error is
public static void main(String[] args) throws Exception{
Configuration conf = new Configuration();
FileSystem fs = FileSystem.get(conf);
Path path = new Path("/");
System.out.println("Path : "" +
path.toString() + """);
System.out.println(fs.isDirectory(path));
System.out.println(fs.getFileStatus(path).isDir());
}
for Local configuration the code prints :
Path : "/"
true
true
For a new formatted dfs with only one file
/user/enis/file.txt, Path could not be created.
Path : "/"
false
Exception in thread "main"
org.apache.hadoop.ipc.RemoteException: java.io.IOException:
java.lang.IllegalArgumentException: Can not create a Path
from an empty string
at
org.apache.hadoop.fs.Path.checkPathArg(Path.java:82)
at
org.apache.hadoop.fs.Path.<init>(Path.java:90)
at
org.apache.hadoop.dfs.DFSFileInfo.<init>(DFSFileInfo.j
ava:59)
at
org.apache.hadoop.dfs.FSDirectory.getFileInfo(FSDirectory.ja
va:729)
at
org.apache.hadoop.dfs.FSNamesystem.getFileInfo(FSNamesystem.
java:1301)
at
org.apache.hadoop.dfs.NameNode.getFileInfo(NameNode.java:488
)
at
sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.apache.hadoop.ipc.RPC$Server.call(RPC.java:340)
at
org.apache.hadoop.ipc.Server$Handler.run(Server.java:566)
at
org.apache.hadoop.ipc.Client.call(Client.java:470)
at
org.apache.hadoop.ipc.RPC$Invoker.invoke(RPC.java:165)
at org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown
Source)
at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce
ssorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.apache.hadoop.io.retry.RetryInvocationHandler.invokeMeth
od(RetryInvocationHandler.java:82)
at
org.apache.hadoop.io.retry.RetryInvocationHandler.invoke(Ret
ryInvocationHandler.java:59)
at org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown
Source)
at
org.apache.hadoop.dfs.DFSClient.getFileInfo(DFSClient.java:4
30)
at
org.apache.hadoop.dfs.DistributedFileSystem.getFileStatus(Di
stributedFileSystem.java:319)
at
org.apache.hadoop.util.TestIsDir.main(TestIsDir.java:38)
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue
online.
|
|
| Assigned: (HADOOP-1647)
DistributedFileSystem.getFileStatus()
fails for path "/" |
  United States |
2007-07-25 14:36:35 |
[ https://issues.apache.org/jira/browse/HADOOP-1647?page=co
m.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
a> ]
dhruba borthakur reassigned HADOOP-1647:
----------------------------------------
Assignee: dhruba borthakur
> DistributedFileSystem.getFileStatus() fails for path
"/"
>
--------------------------------------------------------
>
> Key: HADOOP-1647
> URL: htt
ps://issues.apache.org/jira/browse/HADOOP-1647
> Project: Hadoop
> Issue Type: Bug
> Components: dfs
> Affects Versions: 0.15.0
> Reporter: Enis Soztutar
> Assignee: dhruba borthakur
> Fix For: 0.15.0
>
>
> DistributedFileSystem#getFileStatus throws the
following exception when invoked with new
Path("/"). LocalFileSystem does not. The code to
produce this error is
>
> public static void main(String[] args) throws
Exception{
> Configuration conf = new Configuration();
> FileSystem fs = FileSystem.get(conf);
> Path path = new Path("/");
> System.out.println("Path : "" +
path.toString() + """);
> System.out.println(fs.isDirectory(path));
> System.out.println(fs.getFileStatus(path).isDir());
> }
>
> for Local configuration the code prints :
>
> Path : "/"
> true
> true
>
> For a new formatted dfs with only one file
/user/enis/file.txt, Path could not be created.
>
> Path : "/"
> false
> Exception in thread "main"
org.apache.hadoop.ipc.RemoteException: java.io.IOException:
java.lang.IllegalArgumentException: Can not create a Path
from an empty string
> at
org.apache.hadoop.fs.Path.checkPathArg(Path.java:82)
> at
org.apache.hadoop.fs.Path.<init>(Path.java:90)
> at
org.apache.hadoop.dfs.DFSFileInfo.<init>(DFSFileInfo.j
ava:59)
> at
org.apache.hadoop.dfs.FSDirectory.getFileInfo(FSDirectory.ja
va:729)
> at
org.apache.hadoop.dfs.FSNamesystem.getFileInfo(FSNamesystem.
java:1301)
> at
org.apache.hadoop.dfs.NameNode.getFileInfo(NameNode.java:488
)
> at
sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.ipc.RPC$Server.call(RPC.java:340)
> at
org.apache.hadoop.ipc.Server$Handler.run(Server.java:566)
> at
org.apache.hadoop.ipc.Client.call(Client.java:470)
> at
org.apache.hadoop.ipc.RPC$Invoker.invoke(RPC.java:165)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce
ssorImpl.java:39)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invokeMeth
od(RetryInvocationHandler.java:82)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invoke(Ret
ryInvocationHandler.java:59)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
org.apache.hadoop.dfs.DFSClient.getFileInfo(DFSClient.java:4
30)
> at
org.apache.hadoop.dfs.DistributedFileSystem.getFileStatus(Di
stributedFileSystem.java:319)
> at
org.apache.hadoop.util.TestIsDir.main(TestIsDir.java:38)
>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue
online.
|
|
| Updated: (HADOOP-1647)
DistributedFileSystem.getFileStatus()
fails for path "/" |
  United States |
2007-07-25 17:53:31 |
[ https://issues.apache.org/jira/browse/HADOOP-1647?page=co
m.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
a> ]
dhruba borthakur updated HADOOP-1647:
-------------------------------------
Attachment: fileStatus.patch
This patch returns "/" as the name of rootDir.
> DistributedFileSystem.getFileStatus() fails for path
"/"
>
--------------------------------------------------------
>
> Key: HADOOP-1647
> URL: htt
ps://issues.apache.org/jira/browse/HADOOP-1647
> Project: Hadoop
> Issue Type: Bug
> Components: dfs
> Affects Versions: 0.15.0
> Reporter: Enis Soztutar
> Assignee: dhruba borthakur
> Fix For: 0.15.0
>
> Attachments: fileStatus.patch
>
>
> DistributedFileSystem#getFileStatus throws the
following exception when invoked with new
Path("/"). LocalFileSystem does not. The code to
produce this error is
>
> public static void main(String[] args) throws
Exception{
> Configuration conf = new Configuration();
> FileSystem fs = FileSystem.get(conf);
> Path path = new Path("/");
> System.out.println("Path : "" +
path.toString() + """);
> System.out.println(fs.isDirectory(path));
> System.out.println(fs.getFileStatus(path).isDir());
> }
>
> for Local configuration the code prints :
>
> Path : "/"
> true
> true
>
> For a new formatted dfs with only one file
/user/enis/file.txt, Path could not be created.
>
> Path : "/"
> false
> Exception in thread "main"
org.apache.hadoop.ipc.RemoteException: java.io.IOException:
java.lang.IllegalArgumentException: Can not create a Path
from an empty string
> at
org.apache.hadoop.fs.Path.checkPathArg(Path.java:82)
> at
org.apache.hadoop.fs.Path.<init>(Path.java:90)
> at
org.apache.hadoop.dfs.DFSFileInfo.<init>(DFSFileInfo.j
ava:59)
> at
org.apache.hadoop.dfs.FSDirectory.getFileInfo(FSDirectory.ja
va:729)
> at
org.apache.hadoop.dfs.FSNamesystem.getFileInfo(FSNamesystem.
java:1301)
> at
org.apache.hadoop.dfs.NameNode.getFileInfo(NameNode.java:488
)
> at
sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.ipc.RPC$Server.call(RPC.java:340)
> at
org.apache.hadoop.ipc.Server$Handler.run(Server.java:566)
> at
org.apache.hadoop.ipc.Client.call(Client.java:470)
> at
org.apache.hadoop.ipc.RPC$Invoker.invoke(RPC.java:165)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce
ssorImpl.java:39)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invokeMeth
od(RetryInvocationHandler.java:82)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invoke(Ret
ryInvocationHandler.java:59)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
org.apache.hadoop.dfs.DFSClient.getFileInfo(DFSClient.java:4
30)
> at
org.apache.hadoop.dfs.DistributedFileSystem.getFileStatus(Di
stributedFileSystem.java:319)
> at
org.apache.hadoop.util.TestIsDir.main(TestIsDir.java:38)
>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue
online.
|
|
| Commented: (HADOOP-1647)
DistributedFileSystem.getFileStatus()
fails for path "/" |
  United States |
2007-07-26 00:11:31 |
[ https://issues.apache.org/jira/browse
/HADOOP-1647?page=com.atlassian.jira.plugin.system.issuetabp
anels:comment-tabpanel#action_12515507 ]
Enis Soztutar commented on HADOOP-1647:
---------------------------------------
Well, i had also fixed this, but haven't time to upload it
*smile*
dhruba, why not we change only, in {{INode#computeName()}}
if (parent != null) {
return parent.computeName() + "/" +
name;
} else {
- return name;
+ return "/";
}
}
> DistributedFileSystem.getFileStatus() fails for path
"/"
>
--------------------------------------------------------
>
> Key: HADOOP-1647
> URL: htt
ps://issues.apache.org/jira/browse/HADOOP-1647
> Project: Hadoop
> Issue Type: Bug
> Components: dfs
> Affects Versions: 0.15.0
> Reporter: Enis Soztutar
> Assignee: dhruba borthakur
> Fix For: 0.15.0
>
> Attachments: fileStatus.patch
>
>
> DistributedFileSystem#getFileStatus throws the
following exception when invoked with new
Path("/"). LocalFileSystem does not. The code to
produce this error is
>
> public static void main(String[] args) throws
Exception{
> Configuration conf = new Configuration();
> FileSystem fs = FileSystem.get(conf);
> Path path = new Path("/");
> System.out.println("Path : "" +
path.toString() + """);
> System.out.println(fs.isDirectory(path));
> System.out.println(fs.getFileStatus(path).isDir());
> }
>
> for Local configuration the code prints :
>
> Path : "/"
> true
> true
>
> For a new formatted dfs with only one file
/user/enis/file.txt, Path could not be created.
>
> Path : "/"
> false
> Exception in thread "main"
org.apache.hadoop.ipc.RemoteException: java.io.IOException:
java.lang.IllegalArgumentException: Can not create a Path
from an empty string
> at
org.apache.hadoop.fs.Path.checkPathArg(Path.java:82)
> at
org.apache.hadoop.fs.Path.<init>(Path.java:90)
> at
org.apache.hadoop.dfs.DFSFileInfo.<init>(DFSFileInfo.j
ava:59)
> at
org.apache.hadoop.dfs.FSDirectory.getFileInfo(FSDirectory.ja
va:729)
> at
org.apache.hadoop.dfs.FSNamesystem.getFileInfo(FSNamesystem.
java:1301)
> at
org.apache.hadoop.dfs.NameNode.getFileInfo(NameNode.java:488
)
> at
sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.ipc.RPC$Server.call(RPC.java:340)
> at
org.apache.hadoop.ipc.Server$Handler.run(Server.java:566)
> at
org.apache.hadoop.ipc.Client.call(Client.java:470)
> at
org.apache.hadoop.ipc.RPC$Invoker.invoke(RPC.java:165)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce
ssorImpl.java:39)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invokeMeth
od(RetryInvocationHandler.java:82)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invoke(Ret
ryInvocationHandler.java:59)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
org.apache.hadoop.dfs.DFSClient.getFileInfo(DFSClient.java:4
30)
> at
org.apache.hadoop.dfs.DistributedFileSystem.getFileStatus(Di
stributedFileSystem.java:319)
> at
org.apache.hadoop.util.TestIsDir.main(TestIsDir.java:38)
>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue
online.
|
|
| Updated: (HADOOP-1647)
DistributedFileSystem.getFileStatus()
fails for path "/" |
  United States |
2007-07-26 00:53:31 |
[ https://issues.apache.org/jira/browse/HADOOP-1647?page=co
m.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
a> ]
Enis Soztutar updated HADOOP-1647:
----------------------------------
Fix Version/s: 0.14.0
Affects Version/s: 0.14.0
It will be good if this patch is applied to 0.14 also.
> DistributedFileSystem.getFileStatus() fails for path
"/"
>
--------------------------------------------------------
>
> Key: HADOOP-1647
> URL: htt
ps://issues.apache.org/jira/browse/HADOOP-1647
> Project: Hadoop
> Issue Type: Bug
> Components: dfs
> Affects Versions: 0.14.0, 0.15.0
> Reporter: Enis Soztutar
> Assignee: dhruba borthakur
> Fix For: 0.14.0, 0.15.0
>
> Attachments: fileStatus.patch
>
>
> DistributedFileSystem#getFileStatus throws the
following exception when invoked with new
Path("/"). LocalFileSystem does not. The code to
produce this error is
>
> public static void main(String[] args) throws
Exception{
> Configuration conf = new Configuration();
> FileSystem fs = FileSystem.get(conf);
> Path path = new Path("/");
> System.out.println("Path : "" +
path.toString() + """);
> System.out.println(fs.isDirectory(path));
> System.out.println(fs.getFileStatus(path).isDir());
> }
>
> for Local configuration the code prints :
>
> Path : "/"
> true
> true
>
> For a new formatted dfs with only one file
/user/enis/file.txt, Path could not be created.
>
> Path : "/"
> false
> Exception in thread "main"
org.apache.hadoop.ipc.RemoteException: java.io.IOException:
java.lang.IllegalArgumentException: Can not create a Path
from an empty string
> at
org.apache.hadoop.fs.Path.checkPathArg(Path.java:82)
> at
org.apache.hadoop.fs.Path.<init>(Path.java:90)
> at
org.apache.hadoop.dfs.DFSFileInfo.<init>(DFSFileInfo.j
ava:59)
> at
org.apache.hadoop.dfs.FSDirectory.getFileInfo(FSDirectory.ja
va:729)
> at
org.apache.hadoop.dfs.FSNamesystem.getFileInfo(FSNamesystem.
java:1301)
> at
org.apache.hadoop.dfs.NameNode.getFileInfo(NameNode.java:488
)
> at
sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.ipc.RPC$Server.call(RPC.java:340)
> at
org.apache.hadoop.ipc.Server$Handler.run(Server.java:566)
> at
org.apache.hadoop.ipc.Client.call(Client.java:470)
> at
org.apache.hadoop.ipc.RPC$Invoker.invoke(RPC.java:165)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce
ssorImpl.java:39)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invokeMeth
od(RetryInvocationHandler.java:82)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invoke(Ret
ryInvocationHandler.java:59)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
org.apache.hadoop.dfs.DFSClient.getFileInfo(DFSClient.java:4
30)
> at
org.apache.hadoop.dfs.DistributedFileSystem.getFileStatus(Di
stributedFileSystem.java:319)
> at
org.apache.hadoop.util.TestIsDir.main(TestIsDir.java:38)
>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue
online.
|
|
| Updated: (HADOOP-1647)
DistributedFileSystem.getFileStatus()
fails for path "/" |
  United States |
2007-07-26 03:05:31 |
[ https://issues.apache.org/jira/browse/HADOOP-1647?page=co
m.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
a> ]
Enis Soztutar updated HADOOP-1647:
----------------------------------
Attachment: getFileStatusJavadoc.patch
One line patch for slightly annoying javadoc.
> DistributedFileSystem.getFileStatus() fails for path
"/"
>
--------------------------------------------------------
>
> Key: HADOOP-1647
> URL: htt
ps://issues.apache.org/jira/browse/HADOOP-1647
> Project: Hadoop
> Issue Type: Bug
> Components: dfs
> Affects Versions: 0.14.0, 0.15.0
> Reporter: Enis Soztutar
> Assignee: dhruba borthakur
> Fix For: 0.14.0, 0.15.0
>
> Attachments: fileStatus.patch,
getFileStatusJavadoc.patch
>
>
> DistributedFileSystem#getFileStatus throws the
following exception when invoked with new
Path("/"). LocalFileSystem does not. The code to
produce this error is
>
> public static void main(String[] args) throws
Exception{
> Configuration conf = new Configuration();
> FileSystem fs = FileSystem.get(conf);
> Path path = new Path("/");
> System.out.println("Path : "" +
path.toString() + """);
> System.out.println(fs.isDirectory(path));
> System.out.println(fs.getFileStatus(path).isDir());
> }
>
> for Local configuration the code prints :
>
> Path : "/"
> true
> true
>
> For a new formatted dfs with only one file
/user/enis/file.txt, Path could not be created.
>
> Path : "/"
> false
> Exception in thread "main"
org.apache.hadoop.ipc.RemoteException: java.io.IOException:
java.lang.IllegalArgumentException: Can not create a Path
from an empty string
> at
org.apache.hadoop.fs.Path.checkPathArg(Path.java:82)
> at
org.apache.hadoop.fs.Path.<init>(Path.java:90)
> at
org.apache.hadoop.dfs.DFSFileInfo.<init>(DFSFileInfo.j
ava:59)
> at
org.apache.hadoop.dfs.FSDirectory.getFileInfo(FSDirectory.ja
va:729)
> at
org.apache.hadoop.dfs.FSNamesystem.getFileInfo(FSNamesystem.
java:1301)
> at
org.apache.hadoop.dfs.NameNode.getFileInfo(NameNode.java:488
)
> at
sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.ipc.RPC$Server.call(RPC.java:340)
> at
org.apache.hadoop.ipc.Server$Handler.run(Server.java:566)
> at
org.apache.hadoop.ipc.Client.call(Client.java:470)
> at
org.apache.hadoop.ipc.RPC$Invoker.invoke(RPC.java:165)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce
ssorImpl.java:39)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invokeMeth
od(RetryInvocationHandler.java:82)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invoke(Ret
ryInvocationHandler.java:59)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
org.apache.hadoop.dfs.DFSClient.getFileInfo(DFSClient.java:4
30)
> at
org.apache.hadoop.dfs.DistributedFileSystem.getFileStatus(Di
stributedFileSystem.java:319)
> at
org.apache.hadoop.util.TestIsDir.main(TestIsDir.java:38)
>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue
online.
|
|
| Commented: (HADOOP-1647)
DistributedFileSystem.getFileStatus()
fails for path "/" |
  United States |
2007-07-26 07:58:40 |
[ https://issues.apache.org/jira/browse
/HADOOP-1647?page=com.atlassian.jira.plugin.system.issuetabp
anels:comment-tabpanel#action_12515649 ]
Enis Soztutar commented on HADOOP-1647:
---------------------------------------
It seems that my version of the patch
{{INode#computeName()}} fails other unit tests. I guess the
root node is not the only one with parent being null.
> DistributedFileSystem.getFileStatus() fails for path
"/"
>
--------------------------------------------------------
>
> Key: HADOOP-1647
> URL: htt
ps://issues.apache.org/jira/browse/HADOOP-1647
> Project: Hadoop
> Issue Type: Bug
> Components: dfs
> Affects Versions: 0.14.0, 0.15.0
> Reporter: Enis Soztutar
> Assignee: dhruba borthakur
> Fix For: 0.14.0, 0.15.0
>
> Attachments: fileStatus.patch,
getFileStatusJavadoc.patch
>
>
> DistributedFileSystem#getFileStatus throws the
following exception when invoked with new
Path("/"). LocalFileSystem does not. The code to
produce this error is
>
> public static void main(String[] args) throws
Exception{
> Configuration conf = new Configuration();
> FileSystem fs = FileSystem.get(conf);
> Path path = new Path("/");
> System.out.println("Path : "" +
path.toString() + """);
> System.out.println(fs.isDirectory(path));
> System.out.println(fs.getFileStatus(path).isDir());
> }
>
> for Local configuration the code prints :
>
> Path : "/"
> true
> true
>
> For a new formatted dfs with only one file
/user/enis/file.txt, Path could not be created.
>
> Path : "/"
> false
> Exception in thread "main"
org.apache.hadoop.ipc.RemoteException: java.io.IOException:
java.lang.IllegalArgumentException: Can not create a Path
from an empty string
> at
org.apache.hadoop.fs.Path.checkPathArg(Path.java:82)
> at
org.apache.hadoop.fs.Path.<init>(Path.java:90)
> at
org.apache.hadoop.dfs.DFSFileInfo.<init>(DFSFileInfo.j
ava:59)
> at
org.apache.hadoop.dfs.FSDirectory.getFileInfo(FSDirectory.ja
va:729)
> at
org.apache.hadoop.dfs.FSNamesystem.getFileInfo(FSNamesystem.
java:1301)
> at
org.apache.hadoop.dfs.NameNode.getFileInfo(NameNode.java:488
)
> at
sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.ipc.RPC$Server.call(RPC.java:340)
> at
org.apache.hadoop.ipc.Server$Handler.run(Server.java:566)
> at
org.apache.hadoop.ipc.Client.call(Client.java:470)
> at
org.apache.hadoop.ipc.RPC$Invoker.invoke(RPC.java:165)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce
ssorImpl.java:39)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invokeMeth
od(RetryInvocationHandler.java:82)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invoke(Ret
ryInvocationHandler.java:59)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
org.apache.hadoop.dfs.DFSClient.getFileInfo(DFSClient.java:4
30)
> at
org.apache.hadoop.dfs.DistributedFileSystem.getFileStatus(Di
stributedFileSystem.java:319)
> at
org.apache.hadoop.util.TestIsDir.main(TestIsDir.java:38)
>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue
online.
|
|
| Commented: (HADOOP-1647)
DistributedFileSystem.getFileStatus()
fails for path "/" |
  United States |
2007-07-26 12:23:06 |
[ https://issues.apache.org/jira/browse
/HADOOP-1647?page=com.atlassian.jira.plugin.system.issuetabp
anels:comment-tabpanel#action_12515795 ]
dhruba borthakur commented on HADOOP-1647:
------------------------------------------
Hi Enis, i think ur patch might cause problems in some other
areas. Especially if u rin the unit tests. Please let me
know if my patch fixes your problem.
> DistributedFileSystem.getFileStatus() fails for path
"/"
>
--------------------------------------------------------
>
> Key: HADOOP-1647
> URL: htt
ps://issues.apache.org/jira/browse/HADOOP-1647
> Project: Hadoop
> Issue Type: Bug
> Components: dfs
> Affects Versions: 0.14.0, 0.15.0
> Reporter: Enis Soztutar
> Assignee: dhruba borthakur
> Fix For: 0.14.0, 0.15.0
>
> Attachments: fileStatus.patch,
getFileStatusJavadoc.patch
>
>
> DistributedFileSystem#getFileStatus throws the
following exception when invoked with new
Path("/"). LocalFileSystem does not. The code to
produce this error is
>
> public static void main(String[] args) throws
Exception{
> Configuration conf = new Configuration();
> FileSystem fs = FileSystem.get(conf);
> Path path = new Path("/");
> System.out.println("Path : "" +
path.toString() + """);
> System.out.println(fs.isDirectory(path));
> System.out.println(fs.getFileStatus(path).isDir());
> }
>
> for Local configuration the code prints :
>
> Path : "/"
> true
> true
>
> For a new formatted dfs with only one file
/user/enis/file.txt, Path could not be created.
>
> Path : "/"
> false
> Exception in thread "main"
org.apache.hadoop.ipc.RemoteException: java.io.IOException:
java.lang.IllegalArgumentException: Can not create a Path
from an empty string
> at
org.apache.hadoop.fs.Path.checkPathArg(Path.java:82)
> at
org.apache.hadoop.fs.Path.<init>(Path.java:90)
> at
org.apache.hadoop.dfs.DFSFileInfo.<init>(DFSFileInfo.j
ava:59)
> at
org.apache.hadoop.dfs.FSDirectory.getFileInfo(FSDirectory.ja
va:729)
> at
org.apache.hadoop.dfs.FSNamesystem.getFileInfo(FSNamesystem.
java:1301)
> at
org.apache.hadoop.dfs.NameNode.getFileInfo(NameNode.java:488
)
> at
sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.ipc.RPC$Server.call(RPC.java:340)
> at
org.apache.hadoop.ipc.Server$Handler.run(Server.java:566)
> at
org.apache.hadoop.ipc.Client.call(Client.java:470)
> at
org.apache.hadoop.ipc.RPC$Invoker.invoke(RPC.java:165)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce
ssorImpl.java:39)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invokeMeth
od(RetryInvocationHandler.java:82)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invoke(Ret
ryInvocationHandler.java:59)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
org.apache.hadoop.dfs.DFSClient.getFileInfo(DFSClient.java:4
30)
> at
org.apache.hadoop.dfs.DistributedFileSystem.getFileStatus(Di
stributedFileSystem.java:319)
> at
org.apache.hadoop.util.TestIsDir.main(TestIsDir.java:38)
>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue
online.
|
|
| Updated: (HADOOP-1647)
DistributedFileSystem.getFileStatus()
fails for path "/" |
  United States |
2007-07-26 18:10:06 |
[ https://issues.apache.org/jira/browse/HADOOP-1647?page=co
m.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
a> ]
dhruba borthakur updated HADOOP-1647:
-------------------------------------
Priority: Blocker (was: Major)
I am marking this as a blocker so that it gets into 0.14.
> DistributedFileSystem.getFileStatus() fails for path
"/"
>
--------------------------------------------------------
>
> Key: HADOOP-1647
> URL: htt
ps://issues.apache.org/jira/browse/HADOOP-1647
> Project: Hadoop
> Issue Type: Bug
> Components: dfs
> Affects Versions: 0.14.0, 0.15.0
> Reporter: Enis Soztutar
> Assignee: dhruba borthakur
> Priority: Blocker
> Fix For: 0.14.0, 0.15.0
>
> Attachments: fileStatus.patch,
getFileStatusJavadoc.patch
>
>
> DistributedFileSystem#getFileStatus throws the
following exception when invoked with new
Path("/"). LocalFileSystem does not. The code to
produce this error is
>
> public static void main(String[] args) throws
Exception{
> Configuration conf = new Configuration();
> FileSystem fs = FileSystem.get(conf);
> Path path = new Path("/");
> System.out.println("Path : "" +
path.toString() + """);
> System.out.println(fs.isDirectory(path));
> System.out.println(fs.getFileStatus(path).isDir());
> }
>
> for Local configuration the code prints :
>
> Path : "/"
> true
> true
>
> For a new formatted dfs with only one file
/user/enis/file.txt, Path could not be created.
>
> Path : "/"
> false
> Exception in thread "main"
org.apache.hadoop.ipc.RemoteException: java.io.IOException:
java.lang.IllegalArgumentException: Can not create a Path
from an empty string
> at
org.apache.hadoop.fs.Path.checkPathArg(Path.java:82)
> at
org.apache.hadoop.fs.Path.<init>(Path.java:90)
> at
org.apache.hadoop.dfs.DFSFileInfo.<init>(DFSFileInfo.j
ava:59)
> at
org.apache.hadoop.dfs.FSDirectory.getFileInfo(FSDirectory.ja
va:729)
> at
org.apache.hadoop.dfs.FSNamesystem.getFileInfo(FSNamesystem.
java:1301)
> at
org.apache.hadoop.dfs.NameNode.getFileInfo(NameNode.java:488
)
> at
sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.ipc.RPC$Server.call(RPC.java:340)
> at
org.apache.hadoop.ipc.Server$Handler.run(Server.java:566)
> at
org.apache.hadoop.ipc.Client.call(Client.java:470)
> at
org.apache.hadoop.ipc.RPC$Invoker.invoke(RPC.java:165)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce
ssorImpl.java:39)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invokeMeth
od(RetryInvocationHandler.java:82)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invoke(Ret
ryInvocationHandler.java:59)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
org.apache.hadoop.dfs.DFSClient.getFileInfo(DFSClient.java:4
30)
> at
org.apache.hadoop.dfs.DistributedFileSystem.getFileStatus(Di
stributedFileSystem.java:319)
> at
org.apache.hadoop.util.TestIsDir.main(TestIsDir.java:38)
>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue
online.
|
|
| Commented: (HADOOP-1647)
DistributedFileSystem.getFileStatus()
fails for path "/" |
  United States |
2007-07-26 18:23:03 |
[ https://issues.apache.org/jira/browse
/HADOOP-1647?page=com.atlassian.jira.plugin.system.issuetabp
anels:comment-tabpanel#action_12515905 ]
Raghu Angadi commented on HADOOP-1647:
--------------------------------------
I am curious how Enis' patch above is functionally
different? Is there any case where rootDir has non null
parent?
> DistributedFileSystem.getFileStatus() fails for path
"/"
>
--------------------------------------------------------
>
> Key: HADOOP-1647
> URL: htt
ps://issues.apache.org/jira/browse/HADOOP-1647
> Project: Hadoop
> Issue Type: Bug
> Components: dfs
> Affects Versions: 0.14.0, 0.15.0
> Reporter: Enis Soztutar
> Assignee: dhruba borthakur
> Priority: Blocker
> Fix For: 0.14.0, 0.15.0
>
> Attachments: fileStatus.patch,
getFileStatusJavadoc.patch
>
>
> DistributedFileSystem#getFileStatus throws the
following exception when invoked with new
Path("/"). LocalFileSystem does not. The code to
produce this error is
>
> public static void main(String[] args) throws
Exception{
> Configuration conf = new Configuration();
> FileSystem fs = FileSystem.get(conf);
> Path path = new Path("/");
> System.out.println("Path : "" +
path.toString() + """);
> System.out.println(fs.isDirectory(path));
> System.out.println(fs.getFileStatus(path).isDir());
> }
>
> for Local configuration the code prints :
>
> Path : "/"
> true
> true
>
> For a new formatted dfs with only one file
/user/enis/file.txt, Path could not be created.
>
> Path : "/"
> false
> Exception in thread "main"
org.apache.hadoop.ipc.RemoteException: java.io.IOException:
java.lang.IllegalArgumentException: Can not create a Path
from an empty string
> at
org.apache.hadoop.fs.Path.checkPathArg(Path.java:82)
> at
org.apache.hadoop.fs.Path.<init>(Path.java:90)
> at
org.apache.hadoop.dfs.DFSFileInfo.<init>(DFSFileInfo.j
ava:59)
> at
org.apache.hadoop.dfs.FSDirectory.getFileInfo(FSDirectory.ja
va:729)
> at
org.apache.hadoop.dfs.FSNamesystem.getFileInfo(FSNamesystem.
java:1301)
> at
org.apache.hadoop.dfs.NameNode.getFileInfo(NameNode.java:488
)
> at
sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.ipc.RPC$Server.call(RPC.java:340)
> at
org.apache.hadoop.ipc.Server$Handler.run(Server.java:566)
> at
org.apache.hadoop.ipc.Client.call(Client.java:470)
> at
org.apache.hadoop.ipc.RPC$Invoker.invoke(RPC.java:165)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce
ssorImpl.java:39)
> at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
> at
java.lang.reflect.Method.invoke(Method.java:585)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invokeMeth
od(RetryInvocationHandler.java:82)
> at
org.apache.hadoop.io.retry.RetryInvocationHandler.invoke(Ret
ryInvocationHandler.java:59)
> at
org.apache.hadoop.dfs.$Proxy0.getFileInfo(Unknown Source)
> at
org.apache.hadoop.dfs.DFSClient.getFileInfo(DFSClient.java:4
30)
> at
org.apache.hadoop.dfs.DistributedFileSystem.getFileStatus(Di
stributedFileSystem.java:319)
> at
org.apache.hadoop.util.TestIsDir.main(TestIsDir.java:38)
>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue
online.
|
|