hadoop fs:du & count统计hdfs文件(目录下文件)大小的用法

hadoop fs 更多用法,请参考官网:http://hadoop.apache.org/docs/r1.0.4/cn/hdfs_shell.html

以下是我的使用hadoop fs -du统计文件时使用的记录:

[t@dv00938 ~]$ hadoop fs -ls /jc_rc/rc_hive_db/llcfpd_s_join_n_over0innerdoor_lishui
// :: INFO hdfs.PeerCache: SocketCache disabled.
Found items
-rwxrwx---+ t_user t_user_group -- : /t_user/my_hive_db/my_hive_table_test01/000000_0
-rwxrwx---+ t_user t_user_group -- : /t_user/my_hive_db/my_hive_table_test01/000001_0
-rwxrwx---+ t_user t_user_group -- : /t_user/my_hive_db/my_hive_table_test01/000002_0
-rwxrwx---+ t_user t_user_group -- : /t_user/my_hive_db/my_hive_table_test01/000003_0
-rwxrwx---+ t_user t_user_group -- : /t_user/my_hive_db/my_hive_table_test01/000004_0
-rwxrwx---+ t_user t_user_group -- : /t_user/my_hive_db/my_hive_table_test01/000005_0
...
[t@dv00938 ~]$ hadoop fs -du /t_user/my_hive_db/my_hive_table_test01
// :: INFO hdfs.PeerCache: SocketCache disabled.
/t_user/my_hive_db/my_hive_table_test01/000000_0
/t_user/my_hive_db/my_hive_table_test01/000001_0
/t_user/my_hive_db/my_hive_table_test01/000002_0
/t_user/my_hive_db/my_hive_table_test01/000003_0
/t_user/my_hive_db/my_hive_table_test01/000004_0
/t_user/my_hive_db/my_hive_table_test01/000005_0
...
[t@dv00938 ~]$ hadoop fs -du -h /t_user/my_hive_db/my_hive_table_test01
// :: INFO hdfs.PeerCache: SocketCache disabled.
269.1 M /t_user/my_hive_db/my_hive_table_test01/000000_0
268.4 M /t_user/my_hive_db/my_hive_table_test01/000001_0
268.0 M /t_user/my_hive_db/my_hive_table_test01/000002_0
267.8 M /t_user/my_hive_db/my_hive_table_test01/000003_0
267.4 M /t_user/my_hive_db/my_hive_table_test01/000004_0
266.8 M /t_user/my_hive_db/my_hive_table_test01/000005_0
...
[t@dv00938 ~]$ hadoop fs -du -s /t_user/my_hive_db/my_hive_table_test01
// :: INFO hdfs.PeerCache: SocketCache disabled.
/t_user/my_hive_db/my_hive_table_test01 [t@dv00938 ~]$ hadoop fs -du -s -h /t_user/my_hive_db/my_hive_table_test01
// :: INFO hdfs.PeerCache: SocketCache disabled.
27.9 G /t_user/my_hive_db/my_hive_table_test01

hadoop fs -count

[dx@d- conf]$ hadoop fs -count /user/dx/
/user/dx
[dx@d- conf]$ hadoop fs -count /user/dx/*
12 4 45844 /user/dx/.Trash
15 502 2382220393 /user/dx/.sparkStaging
1 2 28116579 /user/dx/base_data
45212 109771 23930279854 /user/dx/streaming
上一篇:所使用的“System.Web.Mvc, Version=3.0.0.1, Culture=neutral, PublicKeyToken=31bf3856ad364e35”版本高于所引用的程序集“System.Web.Mvc, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35”的版本


下一篇:Android控件——AutoCompleteTextView与MultiAutoCompleteTextView(实现自动匹配输入的内容)