Pulseaudio not starting on reboot

For the last week or 2 I’ve had a wierd situation where on reboot of my L5, pulseaudio is not automatically starting. I have to manually start it with pulseaudio --start . Has this happened to anyone else? Where should I look to validate that services are starting up correctly, or that they are configured for autostart?

The phone has been my daily driver for the last 6 months, everything running fine. I’m on Byzantium, do updates, etc. Not sure what happened all of a sudden.

2 Likes

No, at least not with me.

Probably systemd, which uses systemctl as a command.

what do “systemctl status --user pulseaudio.socket” and “systemctl status --user pulseaudio.service” show ?

1 Like

This is what I get.

pulseaudio.socket - Sound System
Loaded: loaded (/usr/lib/systemd/user/pulseaudio.socket; enabled; vendor preset: enabled)
Active: failed (Result: service-start-limit-hit) since Mon 2024-03-11 23:42:07 MDT; 13h ago
Triggers: ● pulseaudio.service
Listen: /run/user/1000/pulse/native (Stream)

systemd[1005]: Listening on Sound System.
systemd[1005]: pulseaudio.socket: Failed with result ‘service-start-limit-hit’.

pulseaudio.service - Sound Service
Loaded: loaded (/usr/lib/systemd/user/pulseaudio.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Mon 2024-03-11 23:42:07 MDT; 13h ago
TriggeredBy: ● pulseaudio.socket
Process: 1201 ExecStart=/usr/bin/pulseaudio --daemonize=no --log-target=journal (code=exited, status=1/FAILURE)
Main PID: 1201 (code=exited, status=1/FAILURE)
CPU: 185ms

systemd[1005]: pulseaudio.service: Scheduled restart job, restart counter is at 5.
systemd[1005]: Stopped Sound Service.
systemd[1005]: pulseaudio.service: Start request repeated too quickly.
systemd[1005]: pulseaudio.service: Failed with result ‘exit-code’.
systemd[1005]: Failed to start Sound Service.

1 Like

what both of these show ?

journalctl --user-unit pulseaudio.service

journalctl --user-unit pulseaudio.socket

1 Like

Here is some of the output. Does this help. It seems like my profile got corrupted?

systemd[1006]: Starting Sound Service…
pulseaudio[1035]: Failed to find a working profile.
pulseaudio[1035]: Failed to load module “module-alsa-card” (argument: “device_id=“Modem” name=“platform-sound-wwan” card_properties=“device.description=Modem””): initialization failed.
pulseaudio[1035]: No sink found by this name or index.
pulseaudio[1035]: Failed to initialize daemon due to errors while executing startup commands. Source of commands: /etc/pulse/librem5.pa
systemd[1006]: pulseaudio.service: Main process exited, code=exited, status=1/FAILURE
systemd[1006]: pulseaudio.service: Failed with result ‘exit-code’.
systemd[1006]: Failed to start Sound Service.
systemd[1006]: pulseaudio.service: Scheduled restart job, restart counter is at 1.
systemd[1006]: Stopped Sound Service.

systemd[1006]: Listening on Sound System.
systemd[1006]: pulseaudio.socket: Failed with result ‘service-start-limit-hit’.
– Boot 5d96a979c6f84df29f8b73cf26a5b00e –
systemd[1014]: Listening on Sound System.
systemd[1014]: pulseaudio.socket: Succeeded.
systemd[1014]: Closed Sound System.
– Boot 28f85c6f91714c3ea5845457dc1337f6 –
systemd[1005]: Listening on Sound System.
systemd[1005]: pulseaudio.socket: Failed with result ‘service-start-limit-hit’.
– Boot 23fb4621d7d0405ba04fc9adc9ffe5ba –

1 Like

I think the reason why you are getting this

Failed to initialize daemon due to errors while executing startup commands. Source of commands: /etc/pulse/librem5.pa

is because of this

Failed to load module “module-alsa-card” (argument: “device_id=“Modem” name=“platform-sound-wwan” card_properties=“device.description=Modem””): initialization failed.

something easy you can do first is to do this

sudo apt reinstall librem5-base-defaults

this is going to reinstall librem5.pa

restart and see if it fixed your issue though i doubt it will

Do you know if this happened after an update ?

2 Likes

Thanks so much for your help @Moon3 ! I reinstalled librem5-base-defaults, rebooted and still the problem.

It might have occurred after an update. Although I’ve been having problems for the last month with the L5 freezing and I need to do a hard shutdown (hold the power button until it shuts down). I think the freezing problem is due to some combination of: vpn - suspend mode - docking.

I have access to protonvpn and mullvadvpn. I’ve used protonvpn because it seems to handle resume from suspend better. But, after an update a month or so ago it locks up the phone on resume. I tried mullvad, but it doesn’t handle it well.

L5 has been suspending and resuming reasonably well, but I’ve had more problems of late. More recently while docked to my hoyoki dock, it has been having more problems with both suspend and docking/undocking.

I think having to do so much hard shutdown / reboot has messed with some profile settings.

I might have to resort to reflashing this weekend. I do have backups, etc and I’m used to that. I’m trying to see if I can understand what may be getting messed up. But, I might have to just learn to do without vpn for now? Not sure. I have learned that wireguard definitely creates more problems than using openvpn. Mostly for dealing with MMS though.

I am hoping I can get the pulseaudio profiles re-established. It would be nice if re-installing the packages would do that, but that doesn’t seem to be working. I’ve re-installed pulseaudio, and a whole slew of other librem5 base and gnome packages. But, they haven’t helped.

Thanks anyway! You taught me a lot at looking at systemctl to investigate!

1 Like

sounds similar to this

and this

something you can do is to downgrade the kernel, it might fix the freezing and the pulseaudio problem.

2 Likes

Thanks for that info! Good to know it isn’t just my bad habits.

I was able to downgrade the kernel to 6.5 that I had installed and now the pulseaudio does start up. no problem. So, that is a kernel issue?!

But, now my power / battery icon is showing no battery installed ?! :slight_smile: I’ll try and reinstall some base packages and see if that helps.

1 Like

Interesting, I did a search of my librem5 installed packages and realized I had some packages from the Byzantium updates proposed (main). I usually keep this repo deactivated, but I must have forgotten to unset it. When I turned that repo off, and reinstalled some of the librem5 packages from that repo, now the battery indicator works normally.

There must be some conflict with the packages in the Proposed repo, that are conflicting.

Thanks again @Moon3 ! My L5 seems somewhat stable again. Still on the 6.5 kernel. I’ll see if I can get back onto the 6.6 kernel and see if I still have the pulseaudio problems (when not having packages from the Proposed repo installed).

1 Like

Question though: Did the OP save that file before reinstalling and, if so, did it change as a result?

Alternatively …

Since I have kept the Librem 5 disk image around on my host computer, it is possible to mount the disk image on the host computer and check the contents of the file as it would have been at initial installation on the Librem 5 (and, if necessary, diff it against the current file on the Librem 5 using sshfs).

It looks as if this has been overtaken by events though i.e. working better now.

2 Likes

I’m not sure if librem5.pa is an actual file. I was thinking the intent was to reinstall profile settings associated with pulseaudio.

Regardless, yeah, my original problem appears to be “fixed” in the sense it seems to be related to the new 6.6 kernel, and possibly not working well with a few packages I inadvertently installed from the Proposed repo.

1 Like

It is. However it may have been necessary to look at other files as well.

1 Like

Just wondering if there is any progress on this one as it’s quite annoying and pronounced when using my Nexdock.

2 Likes

I needed to reflash byzantium for other reasons, and I haven’t had this problem since. Can’t tell you what officially caused then solved the problem though.

1 Like