1. copyFromLocal
hadoop dfs -copyFromLocal /opt/tmp /user/hduser/gutenberg
2.ls
hadoop dfs -ls
输出:/user/hduser/gutenberg
hadoop dfs -ls /user/hduser/gutenberg
输出:
-rw-r--r-- 3 hduser supergroup 674566 2011-03-10 11:38 /user/hduser/gutenberg/pg20417.txt
-rw-r--r-- 3 hduser supergroup 1573112 2011-03-10 11:38 /user/hduser/gutenberg/pg4300.txt
-rw-r--r-- 3 hduser supergroup 1423801 2011-03-10 11:38 /user/hduser/gutenberg/pg5000.txt
3.rmr 删除文件夹
hadoop dfs -rmr /user/hduser/gutenberg(删除文件夹gutenberg及其所有内容)
阅读(947) | 评论(0) | 转发(0) |