Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/image-processing/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
java.lang.NoSuchMethodError:org.apache.hadoop.ipc.RPC.getProxy在创建hdfs目录时_Hadoop_Hdfs - Fatal编程技术网

java.lang.NoSuchMethodError:org.apache.hadoop.ipc.RPC.getProxy在创建hdfs目录时

java.lang.NoSuchMethodError:org.apache.hadoop.ipc.RPC.getProxy在创建hdfs目录时,hadoop,hdfs,Hadoop,Hdfs,FileSystem.getConfig(config)在尝试创建HDFS目录时抛出org.apache.hadoop.ipc.RPC.getProxy异常 config.addResource(new Path(String.format("%s/core-site.xml",TestProperties.HDFS_CONF_DIR))); config.addResource(new Path(String.format("%s/hdfs-site.xml",TestProperties.H

FileSystem.getConfig(config)
在尝试创建HDFS目录时抛出
org.apache.hadoop.ipc.RPC.getProxy异常

config.addResource(new Path(String.format("%s/core-site.xml",TestProperties.HDFS_CONF_DIR)));
config.addResource(new Path(String.format("%s/hdfs-site.xml",TestProperties.HDFS_CONF_DIR)));
config.set("fs.hdfs.impl", org.apache.hadoop.hdfs.DistributedFileSystem.class.getName());
config.set("fs.file.impl", org.apache.hadoop.fs.LocalFileSystem.class.getName());
FileSystem dfs = FileSystem.get(config);
附加完整的堆栈跟踪:

java.lang.NoSuchMethodError: org.apache.hadoop.ipc.RPC.getProxy(Ljava/lang/Class;JLjava/net/InetSocketAddress;Lorg/apache/hadoop/security/UserGroupInformation;Lorg/apache/hadoop/conf/Configuration;Ljavax/net/SocketFactory;ILorg/apache/hadoop/io/retry/RetryPolicy;Z)Lorg/apache/hadoop/ipc/VersionedProtocol; 在 org.apache.hadoop.hdfs.DFSClient.createRPCNamenode(DFSClient.java:135) 位于org.apache.hadoop.hdfs.DFSClient.(DFSClient.java:280) org.apache.hadoop.hdfs.DFSClient.(DFSClient.java:245)位于 org.apache.hadoop.hdfs.DistributedFileSystem.initialize(DistributedFileSystem.java:100) 在 org.apache.hadoop.fs.FileSystem.createFileSystem(FileSystem.java:2761) 位于org.apache.hadoop.fs.FileSystem.access$200(FileSystem.java:99) org.apache.hadoop.fs.FileSystem$Cache.getInternal(FileSystem.java:2795) 位于org.apache.hadoop.fs.FileSystem$Cache.get(FileSystem.java:2777) 位于org.apache.hadoop.fs.FileSystem.get(FileSystem.java:386) org.apache.hadoop.fs.FileSystem.get(FileSystem.java:179)位于 org.apache.atlas.regression.util.HDFSUtil.createDirectory(HDFSUtil.java:46) 在 org.apache.atlas.regression.tests.FalconIntegrationTest.setUp(FalconIntegrationTest.java:43)


集群中的Hadoop版本为2.7.3,pom.xml版本为2.7.3。可能是什么问题?

添加hadoop客户端依赖项解决了问题。添加hadoop客户端依赖项解决了问题。