Re: Filesystem at 100% capacity, what files are large?

From: Oscar del Rio (delrio_at_mie.utoronto.ca)
Date: 08/01/03


Date: Fri, 1 Aug 2003 18:37:20 GMT


Dr. David Kirkby wrote:
>>I was wondering if anyone had a script to find files with a directory
>>and through the sub-directory path that are of a large size or over a
>>specified size so that I can avoid these problems ahead of time in
>>the future.
>
>
> find / -size +50000000b
>
> will find files over 50,000,000 bytes. In fact, if you replace the 'b'
> by 'k', you can find files in kb, rather than bytes, which is a bit
> more useful I would admit.

I don't know what you are running but in Solaris there is no 'b'
or 'k' option in "find -size", only 'c' for bytes.

man find
   -size n[c]
       True if the file is n blocks long (512 bytes per
       block). If n is followed by a c, the size is in bytes.

Solaris (9) find command does not complain about the 'b' or 'k'
suffixes but seems to ignore them, reverting to number of blocks.

Also, avoid searching from the / as it might hang in
special directories (/proc, /xfn) or take forever searching NFS mounts,
unless you restrict the search to the local device.

find /usr /var /export/home -mount -type f -size +10000000c -ls



Relevant Pages

  • Re: The Doctor And Escherichia Coli
    ... farm will strain off the unusual referendum. ... If you will avoid ... Abdullah's script without brakes, ...
    (rec.arts.poems)
  • Re: How to set up a global variable in a sub-routine?
    ... the 'global variables' are more like constants ... ... single script, I need a way to tell it only once where the file is and ... So, if you construct a loop with a loop variable, you ... >programmers avoid global variables completely. ...
    (perl.beginners)
  • Re: Help with emailing attachments with Ruby...
    ... I would really like to avoid going through all the steps of setting up ... I'd use Ruby-Mail or ActionMailer ... thing instead of something wrong with my script. ... # This portion of the code assembles the filenames of the files # ...
    (comp.lang.ruby)
  • Re: Script error
    ... Don't think you are going to be able to avoid the message. ... that MS has addressed the issue of code accessing the outlook address book ... > When I run this script it works, but I get a warning that stats someone is ... > Public Sub meeting() ...
    (microsoft.public.office.developer.vba)
  • Re: Fields dont visualized but necessary
    ... As much as it is possible I try to avoid the copy-paste system. ... Then in A I run a script: ... Set field (gt1, YrField) ... But I am pretty sure that there is another manner to do it more ...
    (comp.databases.filemaker)