How to diagnose memory in linux

  • ps aux --sort rss Link
  • free -m