I have a problem with the audio in Ubuntu 17.10. No sound from speakers unless auto-mute from alsamixer is disabled. In that case sound goes to both speakers and headphones.

All sound cards are installed, however, even when headphones are not connected the only available output remains headphones-internal audio.

So far I did a fresh install of Ubuntu 17.10, run a live version of Ubuntu 16.04, 17.10, and Fedora, but no luck.

All this makes me think of a harware failure, in particular that the switch of headphones output jack socket is not working as it should. I tried to gently clean it, but nothing. However, audio hardware failure is quite unlikely to happen (I hope at least).

After each boot speakers are muted in alsamixer, unmuting them and increasing the volume produce sound from speakers, but of course the speakers are not automatically disabled when headphones are connected.

Note that the audio worked properly with Ubuntu 17.04, and also with 17.10 (at least for a week), then suddenly stopped without updating anything.

Machine: Lenovo Yoga 2 Pro.

arecord -l
**** Lista di CAPTURE dispositivi hardware ****
scheda 1: PCH [HDA Intel PCH], dispositivo 0: ALC3239 Analog [ALC3239 Analog]
  Sottoperiferiche: 1/1
  Sottoperiferica #0: subdevice #0

EDIT: Here the output for cat /proc/asound/card*/codec#*


  • I just tried to run a live usb with Windows and the problem is still there;

  • evtest for mic and heaphones reports them always connected (even if not).

  • I conclude that actually this is a hardware problem. I am going to replace the entire sound card, and I will update this post as soon as I have a final response.

SOLUTION (hardware problem): Replacing the sound board fixed the problem (40 Euros for a new one from eBay).

4 Answers 4


Guess: The laptop BIOS is lying to ALSA, and giving it a wrong headphone jack codec node which always detects "connected".

Look at your analog codec with

cat /proc/asound/card*/codec\#*

and use hdajackretask from package alsa-tools-gui to correct this if it is true.

Also see here for background information.

I don't know why it happened "suddenly", and can't explain the "sudden" change, but that's the first place I'd look. It's probably unrelated to the distro you are using, and it might have been always broken, and your hardware "suddenly" decided to switch from "undetected" to "detected" for the unused node with open pins. Or something complete different.


The Pin Complex info provided by the BIOS looks ok (or at least not as jumbled as the "lying" ones I've seen), so maybe it's something else. Try the following: Run evtest as root, select (in turn) each device that corresponds to soundcard plug events (usually they have HDA Intel or something similar in the name), and plug in/out your headphone and see if you actually receive events. According to the codec, you should have at least two of those, one for the headphone (Node 0x21) and one for the mic (Node 0x19).

Possibly the headphone/mic jack detection hardware is just broken. Or maybe something completely different.

  • Cool thanks, however solving the problem is not really easy even if I think your hint here is fundamental. So far I can see that the jack is not detected as the outpute of cat /proc/asound/card*/codec\#* does not change with/without jack. However, I am a bit confused on how to get this solved using hdajackretask. Could you help me a bit?
    – Caserio
    Commented Oct 30, 2017 at 10:35
  • This output is a codec description as graph of nodes, it's not supposed to contain the connection state. So it won't change with/without jack, those signals appear in the kernel input layer. If you can't make sense of the codec description, please put the output in a pastebin, and edit question with link.
    – dirkt
    Commented Oct 30, 2017 at 12:46

Sorry for digging this. I have the same problem and found a workaround:

  • use hdajackretask to disable the headphone, then the internal speak could work
    • My setting looks like below. I had to Install boot override and reboot to get it to work.
  • Cancelling the override will put the headphone back to work (with a reboot as well).
  • It is likely that some circuit to detect the status of headphone jack is damaged.
  • hdajackretask has many options. My guess is that there could be a combination for both the internal speaker and the headphone to work.

My setup


I had this issue after not installing third party software and update in the first installation step in Ubuntu 20.04 LTS. You should just shift from gdm3 to lightdm to resolve this issue by opening the terminal and typing:

sudo apt-get install lightdm
sudo dpkg-reconfigure lightdm

After entering these commands if you are asked that only one of gdm3 or lightdm ubuntu can use then simply select lightdm when asked. This worked for me.

  1. Check terminal.
  2. Run alsamixer.
  3. Make sure nothing is muted.
  4. And ALSO check that AUTOMUTE IS DISABLED.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .