HiIn hdfs federation mode, when we use a mountable to mount a nonexistent hdfs 
path to views, it is obviously impossible to put file to this viewfs path as it 
is not exist. However, if we try to mkdir this viewfs path, it cannot be 
created because cannot create a folder under InternalDirOfViewfs. Which is 
strange is that return code is 0. Mkdir fails but return code is TRUE. It may 
be something wrong? In the other hand, if we try to use mkdir -p to created a 
deeper folder, the folder can be created successfully.
Take an example, if viewfs:/foo is mounted to hdfs://ns0/footargert and 
hdfs://ns0/footargert does not exist:
1. mkdir /foo, return code 0, but hdfs://ns0/footargert not exist.
2. mkdir -p /foo/xxx, return code 0, folder hdfs://ns0/target and 
hdfs://ns0/target/xxx exist.


I wonder if it has something wrong to get true return code when mkdir actually 
fails. Moreover, is there any strict check that mount to a nonexistent hdfs 
folder is forbidden in mount table setting?


Jiang Jianfei
Best regards

Reply via email to