Skip to content

Instantly share code, notes, and snippets.

View hassan-maavan's full-sized avatar
😏
what else?

Hassan Raza hassan-maavan

😏
what else?
View GitHub Profile
@hassan-maavan
hassan-maavan / clean.sh
Created October 16, 2020 09:39 — forked from Iman/clean.sh
Free up disk space on Ubuntu - clean log, cache, archive packages/apt archives, orphaned packages, old kernel and remove the trash
#!/bin/sh
#Check the Drive Space Used by Cached Files
du -sh /var/cache/apt/archives
#Clean all the log file
#for logs in `find /var/log -type f`; do > $logs; done
logs=`find /var/log -type f`
for i in $logs