You are not logged in.
Hi, on my system I use two separate user accounts for personal and work. I use KDE Plasma as my desktop environment and SDDM as my display manager.
For sound I use an external SMSL AD13 amplifier as my audio device connected via USB, but also keep my motherboard's Realtek audio enabled to make use of the headphone/microphone front connectors.
When I log out of one user account and then log into the other (actually logging out, not KDE's "Switch User"), I lose both those devices, leaving only the motherboard's SPDIF output.
Now I can run usbreset on the SMSL amplifier and then restart pipewire-media-session to get it working again.
What I'm asking is, is there a more elegant solution rather than having to reset my USB device? I feel like I'm using a sledgehammer to crack a nut.
Also just to rule it out, there's no .pacnew files in the /etc/pipewire/media-session.d directory.
Offline
I am having the same issue. I sometimes need to log out of Gnome wayland session and log in to Xorg session. Then this happens.
Restarting the user service you mentioned solves the issue.
I have no DAC, only built-in laptop sound system. This probably rules out the sound device as culprit.
Last edited by icar (2021-04-25 22:52:55)
Online
Created a shell function for it , only to discover almost the same thing exists(what's the chance), I use 'usbip', used it to create a script, rewrote it to this.
Fill in your product number (second behind :colon)
usbreset() {
Product=''
for slink in $(find /sys/bus/usb/devices); do
if [ -e "$slink"/idProduct ] && [ "$(more "$slink"/idProduct)" = "$Product" ]; then
[ "$(cat "$slink"/authorized)" = 1 ] && printf "%s" "0" > "$slink"/authorized || exit 1
sleep 1
printf "%s" "1" > "$slink"/authorized && exit
fi
done
}
It may be a small hammer compared to 'usbreset' ;-)
However, I do think you should open a bug report (systemd?) because a USB device should not be held hostage by a user.
Though, this could be intentional, a usbdisk should be removed safely , a webcam won't mind!
Offline
I don't think it's a hardware bug. My guess is Pipewire on the first user is still "using" the sound devices which doesn't allow the other user to use them without resetting the USB device.
I'll have another look though the system logs to see if there's anything.
Offline