Skip to content

Instantly share code, notes, and snippets.

@jk779
Created April 24, 2016 18:03
Show Gist options
  • Save jk779/11b550d93d22606dd485454221e450d8 to your computer and use it in GitHub Desktop.
Save jk779/11b550d93d22606dd485454221e450d8 to your computer and use it in GitHub Desktop.
clean ubuntu from old kernels
dpkg --list | grep linux-image | awk '{ print $2 }' | sort -V | sed -n '/'`uname -r`'/q;p' | xargs sudo apt-get -y purge
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment