Reputation: 16469
Is there a way to limit the number of files I can cp
in hadoop?
For instance, in my target directory /data/d_20151111-2350/
contains 8 files. These files have random numbers in them so I can't use regex to select a couple. I was wondering if there was something along the lines of
hadoop fs -cp /data/d_20151111-2350/* /dest/location/ LIMIT 2
Where LIMIT 2
means 2 files.
Upvotes: 0
Views: 355
Reputation: 2255
No there is no such a parameter
See also:
https://hadoop.apache.org/docs/r2.4.1/hadoop-project-dist/hadoop-common/FileSystemShell.html#cp
The best way to solve this is writing a python or shell script-
Upvotes: 1