List of directories (and their subdirectories) with hadoop command line

Is there a way to list directories only and their directories recursively with the hadoop command line?

I was wondering if there is some kind of command like the unix command:

find / tmp -type d -print

+3


source to share


2 answers


Try also: (listing directories as root)



hadoop fs -ls -R / | grep "^d"

      

+8


source


Try using this command



hdfs dfs -ls hdfs:/

      

0


source







All Articles