Skip to content

Instantly share code, notes, and snippets.

@jdenoy
Created June 7, 2014 09:32
Show Gist options
  • Save jdenoy/dc52a7644d4a65ac876e to your computer and use it in GitHub Desktop.
Save jdenoy/dc52a7644d4a65ac876e to your computer and use it in GitHub Desktop.
List process' swap usage on linux
#! /bin/sh
for file in /proc/*/status ; do awk '/VmSwap|Name/{printf $2 " " $3}END{ print ""}' $file; done | sort -k 2 -n -r | less
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment