10 Useful Linux / Unix Commands

1. Show/purge unused linux kernel images and modules:

dpkg -l 'linux-*' | sed '/^ii/!d;/'"$(uname -r | sed "s/\(.*\)-\([^0-9]\+\)/\1/")"'/d;s/^[^ ]* [^ ]* \([^ ]*\).*/\1/;/[0-9]/!d'

2. Rip audio from a video file:

mplayer -ao pcm -vo null -vc dummy -dumpaudio -dumpfile <output-file> <input-file>

You can also extract the sound from a flv and make an mp3 with:

ffmpeg -i input.flv -f mp3 -vn -acodec copy ouput.mp3