No announcement yet.

finding large files using shell commands


Unconfigured Ad Widget

  • Filter
  • Time
  • Show
Clear All
new posts

  • finding large files using shell commands

    The below command may be used to find the files that are larger than 20 MB.

    find / -type f -size +20000k -exec ls -lh {} \; | awk '{ print $9 ": " $5 }'

    This command will print the list of files along with the location and size. It will recursively search for such files in root (/)

  • #2
    Re: finding large files using shell commands

    Got it.. below code works for me Thanks..I'm using it is I am running a GREP command on a very large text file to find keywords in the text file from shell script I am executing a command to set a clearcase view after the view is set there is a new subshell comig up in that subshell i want to execute a command then I am displaying to the screen. It does seem to work if then going to Shell mode (Using putty) I executed the command crontab crontab.txt. I run from my desktop but when I try to use it in ASP it timesout iIf you have a suggestion on how to keep this from happening I would appreciate it.