since 1999


3 minutes estimated reading time.

Disable Low Quality Webcam Microphone in Ubuntu Linux 20.04

As a developer and consultant, I attend a lot of Google Meet, Zoom, Microsoft Teams, and other video conference meetings. To this end, I have a really high quality professional Sennheiser e835 microphone and outboard preamp. I actually run this preamp directly into the line in audio port on my desktop’s sound card. The sound quality is top notch and exactly what I want for my video calls. But for some unknown reason my computer will randomly decide that it should switch to the low quality, undesirable sound from the Logitech Webcam. Don’t get me wrong, that webcam is a decent camera and the mic is better than nothing, but I want to use my Sennheiser!

I use Linux for nearly all my work. While I do have a Mac OS system and can run Windows 10 in a virtual machine, my daily driver is a workstation running Ubuntu 20.04. The laptop I carry to client sites or when speaking at conferences is also running Linux on metal. You will increasingly be hearing from me about how to run a business on Linux in the 2020s.

So the issue is, I join a Zoom meeting and have my high quality mic in position when someone says “you sound really distant and quiet”. Perplexed, when I open up the GUI sound configuration it invariably has for some reason jumped over to the webcam like this:

Gnome Sound Dialog with Unwanted Low Quality Webcam Sound

Basically, I never want to use the USB Webcam as an audio input device. Thankfully Linux makes configuration possible. The first step is to determine the USB device ID with the lsusb command. For my C920 webcam the line read as:

Bus 001 Device 016: ID 046d:082d Logitech, Inc. HD Pro Webcam C920

The ID is “046d:082d” and consists of two parts separated by a colon. The four digits before the colon are the vendor ID and the four after the colon are the product ID. With this information in hand, we can create a Dynamic device management (udev) rule to block this input device from being initialized.

Create/edit the rule file with:

sudo vim /etc/udev/rules.d/90-block-webcam-sound.rules

Fill in with the following:

# Do not want low quality webcam mic
SUBSYSTEM=="usb", DRIVER=="snd-usb-audio", ATTRS{idVendor}=="046d", ATTRS{idProduct}=="082d", ATTR{authorized}="0"

Notice that I used the first four characters for ATTRS{idVendor}=="046d" and the second four for ATTRS{idProduct}=="082d". The authorized = 0 attribute tells the udev system to ignore the device.

Once this was done, I reloaded the device settings with:

sudo udevadm control --reload-rules

Then after physically unplugging the USB webcam and plugging it back in, going back to the Gnome sound GUI shows that the unwanted low quality webcam microphone is gone from the list of input devices!

Gnome Sound Dialog with Only High Quality Line In

Now I can just use the Logitech Webcam for video but not sound and be sure that my high quality microphone will be used any time I hop into any call in any application in Ubuntu 20.04!

This should work with other Linux systems as well, but I have only tested it on my own. The original article that I found on this technique is Blacklisting a single USB device from Linux (2014). You can find out more about how the Linux kernel handles this at Authorizing (or not) your USB devices to connect to the system.