You are not logged in.
Hey there,
I have an external USB sound card, a Focusrite Scarlett 18i8, that has quite a lot of options. Fortunately, all of them can be configured using alsamixer, and they also can be saved using alsactl store.
Now, I have the following weird scenario. One of the soundcard's options is a Matrix where you can choose an input and then assign it to any of 8 mixes, which then can be used as a source for an output. In alsamixer, this is simply done by having a setting that chooses the input and then you have 8 volume controls for the 8 mixes. It works fine.
Problem: After reboot, the settings are still there but don't work. By don't work I mean: No sound on the mixes that I have assigned to the output I use. I can fix that by going to the settings in alsamixer and for the two mixes I use, assign a different input and then go back to the input I use. So I just need to change the setting and then can go back to what I wanted in the beginning (and what was saved and apparently loaded). So, the settings are okay, but somehow do not work instantly after a reboot. This issue is reproducible every time.
How could that happen? How can I debug and fix that? Currently, I'm just like wtf, why doesn't it work, everything is fine.
Thanks,
Konzertheld
Offline
please run alsa-info.sh (in alsa-utils) and post the output.
Last edited by Lone_Wolf (2018-04-03 18:13:07)
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
(A works at time B) && (time C > time B ) ≠ (A works at time C)
Offline
Offline
Looks like your focusrite was not plugged in, or alsa-info doesn't list details for usb soundcards.
Please re-run alsa-info while the focusrite is plugged in (and configured correctly).
Full dmesg and/or journal would also help.
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
(A works at time B) && (time C > time B ) ≠ (A works at time C)
Offline
Ooops, my fault. Was plugged in but not turned on. New report: http://www.alsa-project.org/db/?f=7f1a0 … 4ae856c087
The above link is after reboot and pluggin in the Focusrite. No sound. I then change input for Matrix A and B and back, sound works, this is the output afterwards: http://www.alsa-project.org/db/?f=9d4f7 … c4816723aa
dmesg output: https://pastebin.com/GzVCCRS6
Thanks so far!
Offline
running diff -aur on the 2 alsa-info outputs gives :
$ diff -aur bad-7f1a0b3fc9ce8fb598ced8b28b0a204ae856c087.txt good-9d4f7857e0952156783ad8fcd8b110c4816723aa.txt
--- bad-7f1a0b3fc9ce8fb598ced8b28b0a204ae856c087.txt 2018-04-05 10:29:22.467383028 +0200
+++ good-9d4f7857e0952156783ad8fcd8b110c4816723aa.txt 2018-04-05 10:30:14.105313896 +0200
@@ -3,7 +3,7 @@
!!ALSA Information Script v 0.4.64
!!################################
-!!Script ran on: Wed Apr 4 15:25:53 UTC 2018
+!!Script ran on: Wed Apr 4 15:28:51 UTC 2018
!!Linux Distribution
@@ -1207,7 +1207,7 @@
crw-rw---- 1 root audio 116, 10 Apr 4 17:21 /dev/snd/pcmC1D8p
crw-rw---- 1 root audio 116, 11 Apr 4 17:21 /dev/snd/pcmC1D9p
crw-rw---- 1 root audio 116, 18 Apr 4 17:25 /dev/snd/pcmC2D0c
-crw-rw---- 1 root audio 116, 17 Apr 4 17:25 /dev/snd/pcmC2D0p
+crw-rw---- 1 root audio 116, 17 Apr 4 17:28 /dev/snd/pcmC2D0p
crw-rw---- 1 root audio 116, 1 Apr 4 17:21 /dev/snd/seq
crw-rw---- 1 root audio 116, 33 Apr 4 17:21 /dev/snd/timer
@@ -1274,7 +1274,7 @@
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: USB [Scarlett 18i8 USB], device 0: USB Audio [USB Audio]
- Subdevices: 1/1
+ Subdevices: 0/1
Subdevice #0: subdevice #0
ARECORD
@@ -3291,14 +3291,14 @@
control.1 {
iface PCM
name 'Playback Channel Map'
- value.0 0
- value.1 0
- value.2 0
- value.3 0
- value.4 0
- value.5 0
- value.6 0
- value.7 0
+ value.0 3
+ value.1 4
+ value.2 7
+ value.3 8
+ value.4 5
+ value.5 6
+ value.6 12
+ value.7 13
comment {
access read
type INTEGER
$
the value.x lines have to do with the usb card and are what alsactl sees.
What I think may be happening is that the automatic store & restore of alsactl state run too soon or too late.
While the usb card is correctly configured, run alsactl -f /var/lib/alsa/focusrite.state store from CLI (as root) .
shutdown / reboot, make sure the focusrite is powered on .
run alsactl -f /var/lib/alsa/focusrite.state restore from cli as root .
Verify if doing it manually this way restores the setup correctly.
Last edited by Lone_Wolf (2018-04-05 09:11:40)
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
(A works at time B) && (time C > time B ) ≠ (A works at time C)
Offline
I did the following:
- Boot laptop with interface on, after boot, setup everything so that it works
- sudo alsactl -f /var/lib/alsa/focusrite.state store
- reboot laptop
- Check if sound still works - it does, even without manual restore
- Shutdown laptop
- Boot again (with interface still on), check if sound still works - it does, even without manual restore
- Shutdown, turn interface off, turn speakers off, wait a few minutes, turn interface and speakers on again, boot - this time, sound does not work, even with manual restore, same problem as always
- Setup everything so that it works
- Turn off interface and speakers and turn them on again after a few minutes without restarting the laptop - no sound, even with manual restore
- I also checked the position of the soundcard but it was the first one in all the scenarios
Last edited by Konzertheld (2018-04-07 11:59:15)
Offline
Turn off interface and speakers and turn them on again after a few minutes without restarting the laptop - no sound, even with manual restore
Could youd repeat that and post dmesg and/or journal (full from boot is easiest)
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
(A works at time B) && (time C > time B ) ≠ (A works at time C)
Offline
Okay. Boot, media player opened, no sound, fixed everything, sound works, turnd interface off, turned on again, no sound, then journalctl -b --no-tail
This is the output: https://www.dropbox.com/s/su13i6va12nxb … l.txt?dl=0
Offline
How about creating this
alsactl --file ~/.config/asound.state store
reboot and run
alsactl --file ~/.config/asound.state restore
Rules for problems.
Everyone has problems. Animals have problems. And buildings. And cats, and trees.
Problems are your friends. Treat them well.
Offline
archimboldo, I already tried that without success.
Offline
archimboldo, I already tried that without success.
OK. Just an option that came to my mind. Btw, which DE are you running?
Rules for problems.
Everyone has problems. Animals have problems. And buildings. And cats, and trees.
Problems are your friends. Treat them well.
Offline
Sure, thanks for the idea. I use Gnome Shell 3.28.
Offline
Check some options from this link. It may be helpful. https://community.ardour.org/node/8821#comment-47352
Last edited by archimboldo (2018-04-09 08:27:41)
Rules for problems.
Everyone has problems. Animals have problems. And buildings. And cats, and trees.
Problems are your friends. Treat them well.
Offline
Thanks for the link. Some of the GUI tools are nice, but not related to my problem. It does not matter if I set the relevant settings with alsamixer command line or qasmixer or whatever. :\
Offline
Apr 08 19:24:11 atlas kernel: usb 4-1.1: USB disconnect, device number 3
Apr 08 19:24:11 atlas kernel: usb 4-1.1: cannot submit urb (err = -19)
Apr 08 19:24:11 atlas pulseaudio[637]: W: [alsa-sink-USB Audio] alsa-util.c: Got POLLNVAL from ALSA
Apr 08 19:24:11 atlas pulseaudio[637]: W: [alsa-sink-USB Audio] alsa-util.c: Could not recover from POLLERR|POLLNVAL|POLLHUP with snd_pcm_prepare(): Die Dateizugriffsnummer ist in schlechter Verfassung
Apr 08 19:24:11 atlas upowerd[597]: unhandled action 'unbind' on /sys/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.1/4-1.1:1.0
Apr 08 19:24:11 atlas upowerd[597]: unhandled action 'unbind' on /sys/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.1/4-1.1:1.1
Apr 08 19:24:11 atlas upowerd[597]: unhandled action 'unbind' on /sys/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.1/4-1.1:1.2
Apr 08 19:24:11 atlas upowerd[597]: unhandled action 'unbind' on /sys/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.1/4-1.1:1.3
Apr 08 19:24:11 atlas upowerd[597]: unhandled action 'unbind' on /sys/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.1/4-1.1:1.4
Apr 08 19:24:11 atlas upowerd[597]: unhandled action 'unbind' on /sys/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.1
Apr 08 19:24:12 atlas gsd-media-keys[786]: Unable to get default source
Apr 08 19:28:41 atlas kernel: usb 4-1.1: new high-speed USB device number 5 using ehci-pci
Apr 08 19:28:42 atlas kernel: usb 4-1.1: New USB device found, idVendor=1235, idProduct=8014
Apr 08 19:28:42 atlas kernel: usb 4-1.1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Apr 08 19:28:42 atlas kernel: usb 4-1.1: Product: Scarlett 18i8 USB
Apr 08 19:28:42 atlas kernel: usb 4-1.1: Manufacturer: Focusrite
Apr 08 19:28:42 atlas kernel: usb 4-1.1: SerialNumber: 10016575
Apr 08 19:28:42 atlas mtp-probe[1613]: checking bus 4, device 5: "/sys/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.1"
Apr 08 19:28:42 atlas mtp-probe[1613]: bus: 4, device: 5 was not an MTP device
Apr 08 19:28:42 atlas upowerd[597]: unhandled action 'bind' on /sys/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.1/4-1.1:1.2
Apr 08 19:28:42 atlas upowerd[597]: unhandled action 'bind' on /sys/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.1/4-1.1:1.1
Apr 08 19:28:42 atlas upowerd[597]: unhandled action 'bind' on /sys/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.1/4-1.1:1.4
Apr 08 19:28:42 atlas upowerd[597]: unhandled action 'bind' on /sys/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.1/4-1.1:1.3
Apr 08 19:28:42 atlas upowerd[597]: unhandled action 'bind' on /sys/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.1/4-1.1:1.0
Apr 08 19:28:42 atlas upowerd[597]: unhandled action 'bind' on /sys/devices/pci0000:00/0000:00:1d.0/usb4/4-1/4-1.1
The problem appears to be usb related .
Can you boot to mulit-user.target , login to console as user so X / gnome play no part ?
just use aplay to play somethng on the usb card, switch off / switch on and try playing again.
post the journal of it, then we'll have a better idea where to look for the cause.
Last edited by Lone_Wolf (2018-04-11 12:21:25)
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
(A works at time B) && (time C > time B ) ≠ (A works at time C)
Offline
Sorry for the late reply, I moved and had no internet afterwards...
Interestingly, playing sound using aplay in a non-graphical boot does not require any action to make it work. While in graphical boot, I always needed to adjust the parameters with alsamixer as described above, in a non-graphical boot audio just works. I had some keyboard issues so I did not log anything this time, I will hand in some logs later.
Side note: aplay -L shows a lot of cards related to my USB device. I have no idea which one is used in graphical boot, but in non-graphical, I used sysdefault:CARD=USB (I had to supply a device to aplay because the default was the internal sound card).
Full list of USB devices from aplay -L:
sysdefault:CARD=USB
Scarlett 18i8 USB, USB Audio
Default Audio Device
front:CARD=USB,DEV=0
Scarlett 18i8 USB, USB Audio
Front speakers
surround21:CARD=USB,DEV=0
Scarlett 18i8 USB, USB Audio
2.1 Surround output to Front and Subwoofer speakers
surround40:CARD=USB,DEV=0
Scarlett 18i8 USB, USB Audio
4.0 Surround output to Front and Rear speakers
surround41:CARD=USB,DEV=0
Scarlett 18i8 USB, USB Audio
4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=USB,DEV=0
Scarlett 18i8 USB, USB Audio
5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=USB,DEV=0
Scarlett 18i8 USB, USB Audio
5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=USB,DEV=0
Scarlett 18i8 USB, USB Audio
7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
iec958:CARD=USB,DEV=0
Scarlett 18i8 USB, USB Audio
IEC958 (S/PDIF) Digital Audio Output
Offline
Ok, that suggests the problem is not with alsa itself, but with something started later.
Let's first try to exclude display managers.
boot into multi-user.target, login as user, start gnome manually .
Test if things work.
In case they do, the display manager is involved but we'll have a workaround.
If it fails (which i kinda expect) , the DM is not the cause.
Next step should then be to test with a different graphical environment , like openbox or i3.
Last edited by Lone_Wolf (2018-04-21 23:43:51)
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
(A works at time B) && (time C > time B ) ≠ (A works at time C)
Offline
Hey Lone_Wolf, I have no idea why, but apparently the problem disappeared... not sure if it is related to the tests performed in a non-graphical boot or to me setting the pan setting in volume control, but the last days, sound just worked even when laptop and interface were off the whole night and I then booted and turned the interface on afterwards. Very weird...
Thansk for all your help though - I will write again if the problem re-appears.
Offline