GNU/Linux 下尋找佔用硬碟的大檔案

來源:互聯網
上載者:User

     ㈠ 從根目錄尋找大於50MB的檔案,並按大小列表顯示前10個:

[root@Rocky ~]# find / -printf "%k %p\n"|sort -g -k 1,1|\awk '{if($1>50000) print $1/1024 "MB" " " $2}'|tail -n 10111.968MB /mnt/hgfs/vmshare/Disk1/oms/Disk1/stage/Components/oracle.sysman.agent.download/10.2.0.1.0/1/DataFiles/filegroup5.1.1.jar250.258MB /u01/app/oracle/flash_recovery_area/ORACLE10G/datafile/o1_mf_sysaux_8p06vgsb_.dbf260.266MB /u01/app/oracle/oradata/oracle10/sysaux01.dbf318.878MB /mnt/hgfs/vmshare/10201_database_linux32.zip350.157MB /mnt/hgfs/vmshare/B24219-01_4of6.zip467.697MB /mnt/hgfs/vmshare/linux_11gR2_grid.zip480.48MB /u01/app/oracle/flash_recovery_area/ORACLE10G/datafile/o1_mf_system_8p06t0nt_.dbf480.48MB /u01/app/oracle/oradata/oracle10/system01.dbf1500MB /mnt/hgfs/vmshare/vm/vm01.img1677.5MB /mnt/hgfs/vmshare/rhel-server-5.8-i386-dvd.iso

     ㈡ 從目前的目錄開始, 尋找本目錄下大於10M的檔案並顯示詳細資料:

[oracle@Rocky oradata]$ find . -size +10000000c -exec ls -lh {} \;-rw-r----- 1 oracle oinstall 26M Apr  9  2013 ./oracle10/undotbs01.dbf-rw-r----- 1 oracle oinstall 261M Apr  9  2013 ./oracle10/sysaux01.dbf-rw-r----- 1 oracle oinstall 51M Apr  9  2013 ./oracle10/redo02.log-rw-r----- 1 oracle oinstall 21M Apr  8  2013 ./oracle10/temp01.dbf-rw-r----- 1 oracle oinstall 51M Apr  8  2013 ./oracle10/redo03.log-rw-r----- 1 oracle oinstall 481M Apr  9  2013 ./oracle10/system01.dbf-rw-r----- 1 oracle oinstall 51M Apr  8  2013 ./oracle10/redo01.log
相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.