UbuntuThis forum is for the discussion of Ubuntu Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Running (K)Ubuntu 18.04 LTS on HP Elitebook 8440p dual boot with Win10. PulseAudio, everything installed via Discover.
Play audio with nothing connected - sound through internal speakers - ok
Plug headphone in, all software shows the headphones are now connected - no sound at all
Change output from Headphone to Speaker and I get sound in the headphones as desired.
Unplug or reboot and have to repeat process.
This is a consistent anomaly that after 12+ months of working ok has just manifested itself in the past few weeks and first notices on a Zoom session when I couldn't hear anybody. The last Zoom session was fine once I forced headphone=speaker.
There has to be a configuration system file that has a stuck/corrupt setting and help would be much appreciated.
It is a strange issue. Is it just a simple case of speaker/headphone outputs transposed?
What is shown by the following command
Code:
pactl list | grep 'Active Port.*output.*'
a) before the headphones are plugged in?
b) after the headphones are plugged in?
You might also be able to generate some useful diagnostic info in a terminal with
Code:
pulseaudio -k && pulseaudio -vvv
Observe/capture the output from before plugging in the headphones, selecting the speaker output (to get sound), and finally unplugging the headphones again.
It is a strange issue. Is it just a simple case of speaker/headphone outputs transposed?
What is shown by the following command
Code:
pactl list | grep 'Active Port.*output.*'
a) before the headphones are plugged in?
b) after the headphones are plugged in?
You might also be able to generate some useful diagnostic info in a terminal with
Code:
pulseaudio -k && pulseaudio -vvv
Observe/capture the output from before plugging in the headphones, selecting the speaker output (to get sound), and finally unplugging the headphones again.
It is not simply that speaker and headphones are transposed as internal speakers work with nothing connected. Headphones only work after connection and then being instructed to use speaker output. I'll hasten to add that all works as it should when I boot up and into Windows 10, but then it all used to work anyway.
Outputs of tests:
1) Nothing connected:
~$ pactl list | grep 'Active Port.*output.*'
Active Port: analog-output-speaker
2) Headphone connected
~$ pactl list | grep 'Active Port.*output.*'
Active Port: analog-output-headphones
But no sound either from speakers or headphones
3) Now set output to Speakers in System Settings
~$ pactl list | grep 'Active Port.*output.*'
Active Port: analog-output-speaker
Sound comes out of headphones
I'm not sure that I'm seeing any differences in the outputs of:
Code:
pulseaudio -k && pulseaudio -vvv
This is the output with as per Test2 above (headphones but no sound and the first 2 lines and the last are in all three tests. I don't understand enough to know which lines are important.
Code:
I: [pulseaudio] main.c: setrlimit(RLIMIT_NICE, (31, 31)) failed: Operation not permitted
I: [pulseaudio] main.c: setrlimit(RLIMIT_RTPRIO, (9, 9)) failed: Operation not permitted
D: [pulseaudio] core-rtclock.c: Timer slack is set to 50 us.
D: [pulseaudio] core-util.c: RealtimeKit worked.
I: [pulseaudio] core-util.c: Successfully gained nice level -11.
I: [pulseaudio] main.c: This is PulseAudio 11.1
D: [pulseaudio] main.c: Compilation host: x86_64-pc-linux-gnu
D: [pulseaudio] main.c: Compilation CFLAGS: -g -O2 -fdebug-prefix-map=/build/pulseaudio-Ytpi3P/pulseaudio-11.1=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -W -Wextra -pipe -Wno-long-long -Wno-overlength-strings -Wunsafe-loop-optimizations -Wundef -Wformat=2 -Wlogical-op -Wsign-compare -Wformat-security -Wmissing-include-dirs -Wformat-nonliteral -Wpointer-arith -Winit-self -Wdeclaration-after-statement -Wfloat-equal -Wmissing-prototypes -Wredundant-decls -Wmissing-declarations -Wmissing-noreturn -Wshadow -Wendif-labels -Wcast-align -Wstrict-aliasing -Wwrite-strings -Wno-unused-parameter -ffast-math -fno-common -fdiagnostics-show-option -fdiagnostics-color=auto
D: [pulseaudio] main.c: Running on host: Linux x86_64 5.0.0-36-generic #39~18.04.1-Ubuntu SMP Tue Nov 12 11:09:50 UTC 2019
D: [pulseaudio] main.c: Found 4 CPUs.
I: [pulseaudio] main.c: Page size is 4096 bytes
D: [pulseaudio] main.c: Compiled with Valgrind support: no
D: [pulseaudio] main.c: Running in valgrind mode: no
D: [pulseaudio] main.c: Running in VM: no
D: [pulseaudio] main.c: Optimized build: yes
D: [pulseaudio] main.c: FASTPATH defined, only fast path asserts disabled.
I: [pulseaudio] main.c: Machine ID is 448c2d6ad9df4a619a1f3bdc188891d0.
I: [pulseaudio] main.c: Session ID is 3.
I: [pulseaudio] main.c: Using runtime directory /run/user/1000/pulse.
I: [pulseaudio] main.c: Using state directory /home/al/.config/pulse.
I: [pulseaudio] main.c: Using modules directory /usr/lib/pulse-11.1/modules.
I: [pulseaudio] main.c: Running in system mode: no
E: [pulseaudio] pid.c: Daemon already running.
E: [pulseaudio] main.c: pa_pid_file_create() failed.
Last edited by AnthonyL; 06-12-2020 at 07:02 AM.
Reason: Correction to spelling of Test2
This maybe off the track but I note I have a whole load of new .conf files in /usr/share/pulseaudio/alsa-mixer/paths.
The files are dated 14/05/2020 06.20 but I don't know when they were installed but my Headphone issue started towards the end of May.
It is not simply that speaker and headphones are transposed as internal speakers work with nothing connected. Headphones only work after connection and then being instructed to use speaker output. I'll hasten to add that all works as it should when I boot up and into Windows 10, but then it all used to work anyway.
Outputs of tests:
1) Nothing connected:
~$ pactl list | grep 'Active Port.*output.*'
Active Port: analog-output-speaker
2) Headphone connected
~$ pactl list | grep 'Active Port.*output.*'
Active Port: analog-output-headphones
But no sound either from speakers or headphones
3) Now set output to Speakers in System Settings
~$ pactl list | grep 'Active Port.*output.*'
Active Port: analog-output-speaker
Sound comes out of headphones
Ok, thanks for the requested information. Always of benefit to get solid definitive information when trying to help from a distance.
It is what I'd expect for a functioning system, so we need to look elsewhere. A likely PullseAudio issue though.
Quote:
This maybe off the track but I note I have a whole load of new .conf files in /usr/share/pulseaudio/alsa-mixer/paths. The files are dated 14/05/2020 06.20 but I don't know when they were installed but my Headphone issue started towards the end of May.
That is one line of investigation that turns up in online searches for similar symptoms, so could well be relevant here. This regression may well take a bug report to resolve.
IMHO, the files in question (based on your pactl output) are /usr/share/pulseaudio/alsa-mixer/paths/analog-output-speaker.conf and /usr/share/pulseaudio/alsa-mixer/paths/analog-output-headphones.conf perhaps. They're lengthy, so best shared via pastebin or similar. I'll share mine for reference (they're dated Dec 18 2018)...
There are of course many other similarly name .conf files in that folder.
I'll try and compare with yours later in the day but I thought I'd get this out whilst you antipodeans are awake.
At the risk of obfuscating the issue, which has happened when I've posted on other forums, I'll add some background as there may be more clues in there and you may also be in a position to comment.
Firstly I'm a fairly recent Linux user and I'm not young - not a good combination.
I have a project in hand to convert all my analogue (Reel-Reel, Cassettes & Vinyl) to digital and had capture all into Audacity projects on a Windows machine. I've copied all the Vinyl projects to Linux, albeit to a Shared NTFS partition which contains most of my data. So a few weeks ago I started testing cataloging and outputting as mp3 (though Audacity has inconsistencies in ID3 tags), and trying to determine which player I'd prefer over and above VLC (Rhythmbox is winning). All this started about 6 weeks ago and coincided with my hobby group trying to setup a Teams meeting and then swapping to Zoom and I was delighted that both installed fine. My internal mics and speakers aren't brilliant and I prefer earphones so I used those. I also have the USB sound card (quite old) that I used to digitise the analogue and I tried that which gave better sound through the headphones. Sometime during the course of all this I've had Audacity hang. I can't be sure I've always managed to put the right jack in the right socket (whatever happened to the nice Pink and Green; black isn't cool!). One Zoom session failed as people complained about my sound (might have had mic volume too high, don't know) and then I hit the can't hear through headphones and finally I used a Windows Zoom. Somehow I stumbled on switching the setting to Speaker to get sound out of the headphones. There then was a recent update which I noted had a whole load of PulseAudion files and I was hopeful that this would fix the issue but unfortunately not. Diverting again I would have like to have had a backup strategy that would have enabled me to revert and if there is a preferred forum to discuss this I'll post there. I then did the moving of .config/pulse and that seemed to tidy up a lot, though probably only removed references to the USB sound card. After hitting a block on other forums someone suggested I post here and here I am.
I intend to install 20.04 which might provide the solution for this and also for an IMAP issue with Evolution. But I am nervous about losing my boot/grub and in particular when Windows updates and takes command of the machine (I'm still on MBR). I'll do more once I have a backup strategy that is a bit more sophisticated that a simply (though useful) Gparted partition copy.
Apologies for dumping all this on you and I don't expect dialogue here but pointers for further discussion welcomed and there may still be some clues in there for this topic's issue.
Ok, I see nothing significantly different between the files, so maybe we can discount this.
Quote:
I then did the moving of .config/pulse and that seemed to tidy up a lot, though probably only removed references to the USB sound card. After hitting a block on other forums someone suggested I post here and here I am.
That just removes a user's config (including any custom settings), but is regenerated to defaults when next restarted. Any USB device would be dynamically handled at the time it is introduced.
Quote:
Diverting again I would have like to have had a backup strategy that would have enabled me to revert and if there is a preferred forum to discuss this I'll post there.
I'm not an Ubuntu user, so can't comment about what backup tools it has. Best discussed in its own dedicated thread as you already mentioned.
Quote:
Apologies for dumping all this on you and I don't expect dialogue here but pointers for further discussion welcomed and there may still be some clues in there for this topic's issue.
Unfortunately, nothing obvious (too me at east).
Having said that, I did find an interesting HP support page detailing "...plugging in external speakers or headphones does not cut off/route audio from the internal speakers to the external speakers/headphones connected to audio jack of the notebook. Therefore, there is no audio output from the external speakers/headphone." This was with respect to Windows 7, but ultimately due to a hardware quirk that needs to be handled by the hardware driver. Now, this would apply to the Linux (alsa) driver too. Since it was working up until a few weeks back, perhaps it is an alsa-related regression that you've encountered? Hard to say. (A distro/kernel upgrade might therefore be worth trying.)
Let's see any driver-specific options configured here...
Code:
cat /etc/modprobe.d/alsa-base.conf
The systool command can be used to show loaded driver options as well (should be consistent with config file options)...
I would have concerns over the hardware if it didn't all work under Windows 10 (and as best I recall previously under Win7). Last week I did a Zoom session in Windows 10 with all my headsets and Earphones to confirm that the devices and sockets were ok and didn't have random disconnects/broken cables etc.
I haven't used KDE 4 for a few years now (openSUSE Leap has been using KDE Plasma 5 since last several versions now), so can't really offer specific advice unfortunately. It might be worth reaching out to the Kubuntu community...
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.