0

I have a cluster running Hadoop 2.6.0-cdh5.4.1. I want to create a file inside a directory using webhdfs rest api. I have 2 directories called directory1 and directory2, both in /.

They both have the same permissions(711), owner and group.

The following command succeeds:

curl --negotiate -u : https://DatanodeUrl:HttpFSPort/webhdfs/v1/directory1?op=LISTSTATUS

while the following

curl --negotiate -u : https://DatanodeUrl:HttpFSPort/webhdfs/v1/directory2?op=LISTSTATUS 

throws the error

{"message":null,"exception":"NullPointerException","javaClassName":"java.lang.NullPointerException"}.

DatanodeUrl and HttpFSPort are the same for both commands. All webhdfs requests on directory2 fail with the same error(NullPointerException), while all webhdfs requests work on directory1.

Do you have any ideas what can cause this error?

Thank you.

anegru
  • 1,023
  • 2
  • 13
  • 29
  • The second one has the port part twice `:HttpFSPort:HttpFSPort/`. It seems that it should be only one. – Takatoshi Kondo Nov 24 '18 at 00:12
  • It was an unfortunate typo in the question. The command fails with the port written once as well. Thank you for the answer. I edited the question. – anegru Nov 24 '18 at 06:28

0 Answers0