Menu

#2 java.io.IOException: No FileSystem for scheme: hdfs

open
nobody
5
2014-08-26
2012-09-26
No

liam821 reported a problem when trying to get pydoop 0.6.4 to work with CDH4:

https://sourceforge.net/projects/pydoop/forums/forum/990018/topic/5870160

[quote]
-bash-4.1$ python
Python 2.7.3 (default, Sep 20 2012, 22:44:26)
[GCC 4.4.6 20120305 (Red Hat 4.4.6-4)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import pydoop.hdfs as pyhdfs
>>> fs = pyhdfs.fs.hdfs()
12/09/25 11:35:30 ERROR security.UserGroupInformation: PriviledgedActionException as:prdps (auth:SIMPLE) cause:java.io.IOException: No FileSystem for scheme: hdfs
Exception in thread "main" java.io.IOException: No FileSystem for scheme: hdfs
at org.apache.hadoop.fs.FileSystem.getFileSystemClass(FileSystem.java:2138)
at org.apache.hadoop.fs.FileSystem.createFileSystem(FileSystem.java:2145)
at org.apache.hadoop.fs.FileSystem.access$200(FileSystem.java:80)
at org.apache.hadoop.fs.FileSystem$Cache.getInternal(FileSystem.java:2184)
at org.apache.hadoop.fs.FileSystem$Cache.get(FileSystem.java:2166)
at org.apache.hadoop.fs.FileSystem.get(FileSystem.java:302)
at org.apache.hadoop.fs.FileSystem$1.run(FileSystem.java:148)
at org.apache.hadoop.fs.FileSystem$1.run(FileSystem.java:146)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:396)
at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1232)
at org.apache.hadoop.fs.FileSystem.get(FileSystem.java:146)
Call to org.apache.hadoop.fs.Filesystem::get(URI, Configuration) failed!
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/py273/lib/python2.7/site-packages/pydoop/hdfs/fs.py", line 119, in __init__
h, p, u, fs = _get_connection_info(host, port, user)
File "/usr/local/py273/lib/python2.7/site-packages/pydoop/hdfs/fs.py", line 59, in _get_connection_info
fs = hdfs_ext.hdfs_fs(host, port, user)
IOError: Cannot connect to default
>>>
[/quote]

He determined that pydoop isn't settings its classpath correctly and thus doesn't find the jar /usr/lib/hadoop/client/hadoop-hdfs-2.0.0-cdh4.0.1.jar

Discussion