Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've tried :

avconv -f alsa -i pulse recod.wav

..but it doesn't capture anything. Have any idea?

share|improve this question
up vote 8 down vote accepted

The syntax to invoke avconv is nicely explained in the manpage for avconv. From audio recordings the following options are available:

-f: Force input or output file format.
-i: input file name

To record from ALSA we need the format to be alsa, and the input depends on the device we record (usually this will be the defualt device). Then your command should be as follows:

avconv -f alsa -i default record.wav

To simply record from an ALSA device we may consider using the more basic command line tool arecord. This gives the following example command for a 10 second (-d) recording in cd quality (-f) in wav codec (-t):

arecord -d 10 -f cd -t wav -D copy record.wav

To be able to record from an output sink, we may have to choose a duplex audio profile in "Sound Settings --> Hardware":

enter image description here

Unfortunately In >= 13.04 the hardware configuration was removed from the sound settings. To have access to advanced device configurations we need to install and run pavucontrol Install pavucontrol. The duplex profile can then be selected in the Configuration tab:

enter image description here

share|improve this answer
Thanks for the answer, but avconv -f pulse -i default record.wav doesn't work for me..Terminal output hilights this: [pulse @ 0x1dfad60] Estimating duration from bitrate, this may be inaccurate and I end up with a 34KB small wav file.. – Naveen May 9 '13 at 10:16
With ALSA, I'm having 3.8MB file, but there is nothing in it.. just an empty clip. :( – Naveen May 9 '13 at 10:29
Ohmy god! I don't have a hardware tab like yours!... I do have an option to change profile in output tab...but there's no Duplex. I've only got Analog stereo output.... I'm on Raring Ringtail.. – Naveen May 10 '13 at 16:40
Worked this time :) Thanks a lot! – Naveen May 13 '13 at 5:51
Duplex is important if you want to listen to what you record otherwise other settings would work as well for pure recording. I wrote a huge how-to on – Stephan Kristyn May 12 '14 at 23:19

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.