We can use -R
to list files recursively. HDFS: How do you list files recursively?
However, there is no -R
option in hadoop fs -touch
command.
When using the pipe hadoop fs -ls -R <path> | xargs hadoop fs -touch
, it failed with error message
-touch: java.net.URISyntaxException: Relative path in absolute URI
1