Dear User, according to our records you use too much disk space in your home directory. Please delete at least 862312312.29 Megabytes in the next 1.2 days. If you have any questions do not hesitate to send a mail to help-it@zmaw.de. best regards Central IT Services - ZMAW
Have you ever received such an email? If not, perfect! Otherwise you should look at least for the biggest problems:
- Write a function that walks through a directory tree and collects the pathnames and sizes of all files.
- Write a function that sorts the results of the first function according to the size of the files.
- Combine both functions in a script which can be called from the bash.
- Optional: limit the resulting list to the top10 sizes
- Optional: automatically compress the largest files of a certain type.
/Group1 Simon, Fabian
/Group2 Anja, Korbinian, Johannes
/Group3 Stergios, Daniel