df的使用
[root@Carlton scripts]# df -i #查看inode信息Filesystem Inodes IUsed IFree IUse% Mounted on/dev/vda1 2621440 89215 2532225 4% /tmpfs 127498 23 127475 1% /dev/shm/dev/vdb1 25792 11 25781 1% /mnt[root@Carlton scripts]# df -h #单位为M的显示各个区的大小Filesystem Size Used Avail Use% Mounted on/dev/vda1 40G 2.8G 35G 8% /tmpfs 499M 12M 487M 3% /dev/shm/dev/vdb1 94M 1.6M 87M 2% /mnt[root@Carlton scripts]# df -k Filesystem 1K-blocks Used Available Use% Mounted on/dev/vda1 41152832 2887012 36168720 8% /tmpfs 509992 11388 498604 3% /dev/shm/dev/vdb1 95425 1550 88736 2% /mnt[root@Carlton scripts]# df -mFilesystem 1M-blocks Used Available Use% Mounted on/dev/vda1 40189 2820 35322 8% /tmpfs 499 12 487 3% /dev/shm/dev/vdb1 94 2 87 2% /mnt
如何快速找到一个分区占用的大文件
[root@Carlton /]# du -sm *7 bin53 boot1 dev1 download33 etc137 home1 index.html292 lib27 lib641 lost+found1 media1 mnt1 opt
另一种显示方法
[root@Carlton /]# du -sh * # s 是全部显示的意思, h 即单位6.7M bin53M boot428K dev4.0K download33M etc139M home24K index.html292M lib27M lib6416K lost+found4.0K media13K mnt4.0K opt
如果想详细了解,man 帮助