1 |
On 14 July 2014 6:53:30 AM AEST, Joseph <syscon780@×××××.com> wrote: |
2 |
>On 07/13/14 23:25, Dimitri Semitsoglou-Tsiapos wrote: |
3 |
>>On Sun, 13 Jul 2014 14:03:41 -0600 |
4 |
>>Joseph <syscon780@×××××.com> wrote: |
5 |
>> |
6 |
>>> I'm trying to clean up my home directory by locating large disk |
7 |
>>> files. I used: find / -type f -size +20000k -exec ls -lh {} \; | awk |
8 |
>>> '{ print $8 ": " $5 }' |
9 |
>> |
10 |
>>Take a look here regarding why you should never parse ls' output: |
11 |
>>http://mywiki.wooledge.org/ParsingLs |
12 |
>> |
13 |
>>You can use ncdu or xdiskusage (both available in portage) to get more |
14 |
>>useful output. Both will allow you to track down large folders, not |
15 |
>>just single files (for example cache folders tend to hold a large |
16 |
>>amount of tiny files, which may collectively amount for a large chunk |
17 |
>>of your hard disk space). |
18 |
>> |
19 |
> |
20 |
>Thanks folks, so in this case I guess: |
21 |
>find / -type f -size +20000k -exec du -h {} \; |
22 |
> |
23 |
>is the winner (it does the trick). |
24 |
|
25 |
Pipe that through sort -h to get the files sorted by size |
26 |
|
27 |
-- |
28 |
:B |