Skip to content

Instantly share code, notes, and snippets.

@marcanuy
Created November 20, 2013 01:25
Show Gist options
  • Save marcanuy/7555921 to your computer and use it in GitHub Desktop.
Save marcanuy/7555921 to your computer and use it in GitHub Desktop.
Useful shell command
#List user processes with their memory usage and total usage.
ps -u marcanuy -o pid,rss,command | awk '{print $0}{sum+=$2} END {print "Total", sum/1024, "MB"}'
#find all file larger than 500M in home dir
find ~ -type f -size +500M -exec ls -ls {} \; | sort -n
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment