Linux and Python Commands Cheat Sheet ( every growing table )

Delete all size 0 files in a directory:
find . -size 0 -delete
Kill all defunct processes
ps -ef | grep defunct | grep -v grep | cut -b8-20 | xargs kill -9
Kill a specific process by name
ps ax | grep “firefox” | cut -b1-06 | xargs -t kill -9
Find files larger than 500M
find . -type f -size +500M

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.