I want to create a script to check size of all the files present under particular folder, and if size of any file present under a folder cross 500mb it would trigger a mail to me specifying the file name which size have cross above 500mb..


You're not asking any question, just telling us what you're planning to do. But here's what you're probably looking for:

find /path -size +500M -ls | mail -s "large file list" youraddress@example.com
  • I wonder if you're "feeding the trolls" by rewarding a rather poor question... +1 for you though – Xen2050 Apr 28 '16 at 10:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.