I'm trying to figure out the easiest way to capture the audio that my Ubuntu Linux PC is playing and save it to a file. I don't want to capture from a URL. I also don't want to capture through the microphone, or analog capture device. I simply want to capture the bits that are being sent to the sound card. My system uses pulseaudio. I can currently capture the sound with a GUI program called audacity. I'd like to do it with a command-line program instead. I think avconv or arecord can do this, but I've tried dozens of examples and can not get it to work. I think this should be a FAQ, but I can't find anything on the WWW that works. Can someone help out? Thanks.