Specify soundcard by name (e.g. hw:UA101) not working in Ubuntu 11.10

I just upgraded my main machine to Ubuntu 11.10, which I was very hesitant about doing as I can’t exactly say my audio experience has been flawless on my laptop running it. Now when I set up QJacktl to use a device by specifying the name of the card (e.g. hw:UA101 instead of hw:2) I get a whole bunch of errors in the messages window:

Fri Nov 18 17:45:01 2011: Starting jack server…
Fri Nov 18 17:45:01 2011: JACK server starting in realtime mode with priority 10
Fri Nov 18 17:45:01 2011: e[1me[31mERROR: Cannot lock down memory area (Cannot allocate memory)e[0m
Fri Nov 18 17:45:01 2011: e[1me[31mERROR: control open “HW:UA101” (No such file or directory)e[0m
Fri Nov 18 17:45:01 2011: e[1me[31mERROR: control open “HW:UA101” (No such file or directory)e[0m
Fri Nov 18 17:45:01 2011: e[1me[31mERROR: Failed to acquire device name : Audio-1 error : Input/output errore[0m
Fri Nov 18 17:45:01 2011: e[1me[31mERROR: Audio device HW:UA101 cannot be acquired, trying to open it anyway…e[0m
Fri Nov 18 17:45:01 2011: creating alsa driver … HW:UA101|HW:UA101|128|3|48000|0|0|nomon|swmeter|-|32bit
Fri Nov 18 17:45:01 2011: e[1me[31mERROR: control open “HW:UA101” (No such file or directory)e[0m
Fri Nov 18 17:45:01 2011: e[1me[31mERROR: ALSA: Cannot open PCM device alsa_pcm for playback. Falling back to capture-only modee[0m
Fri Nov 18 17:45:01 2011: e[1me[31mERROR: Cannot initialize drivere[0m
Fri Nov 18 17:45:01 2011: e[1me[31mERROR: JackServer::Open() failed with -1e[0m
Fri Nov 18 17:45:01 2011: e[1me[31mERROR: Failed to open servere[0m
17:45:08.835 Could not connect to JACK server as client. - Overall operation failed. - Unable to connect to server. Please check the messages window for more info.
Cannot connect to server socket err = No such file or directory
Cannot connect to server socket
jack server is not running or cannot be started

and a window saying “D-BUS: JACK server could not be started. Sorry”.

I don’t think that anything has changed on my computer apart from the upgrade so I don’t know what is going wrong :S It works when I use hw:2, but I want to be able to specify by name because I use a number of different cards at different times (Intel, UA25, UA101, UA1000)

@chrisophski: what is the output of: cat /proc/asound/cards

@paul:

0 [Intel ]: HDA-Intel - HDA Intel
HDA Intel at 0xfb9f8000 irq 77
1 [HDMI ]: HDA-Intel - HDA ATI HDMI
HDA ATI HDMI at 0xfbcfc000 irq 78
2 [UA101 ]: UA-101 - UA-101
EDIROL UA-101 (serial ZU24693), 48000 Hz at usb-0000:00:1a.7-3, high speed
3 [Camera ]: USB-Audio - USB Video Camera
USB Video Camera at usb-0000:00:1a.7-5, high speed

However, I have managed to solve it somewhat. I found that when I typed in the device and pressed “OK”, qjackctl was changing the lowercase “hw” to uppercase “HW” for some reason. I noticed on my laptop that if I type in uppercase “HW” it makes it lower case, so maybe the thing that is meant to make it lowercase was working in the wrong direction, I don’t know. I managed to solve the problem by deleting the rncbc.org folder in /home/christophski/.config.

I have a similar issue on my computer, trying to run my us-122 on ubuntu 11.10 (upgraded to ubuntustudio). QjackCtl will not start. I tried the above solution, but it did not do anything. Here’s the error-message from jack:

Tue Jan 24 20:48:02 2012: Starting jack server…
Tue Jan 24 20:48:02 2012: JACK server starting in realtime mode with priority 89
Tue Jan 24 20:48:02 2012: control device hw:1
Tue Jan 24 20:48:02 2012: control device hw:1
Tue Jan 24 20:48:02 2012: e[1me[31mERROR: Failed to acquire device name : Audio1 error : Input/output errore[0m
Tue Jan 24 20:48:02 2012: e[1me[31mERROR: Audio device hw:1 cannot be acquired, trying to open it anyway…e[0m
Tue Jan 24 20:48:02 2012: creating alsa driver … hw:1|hw:1|1024|2|48000|0|0|nomon|swmeter|-|32bit
Tue Jan 24 20:48:02 2012: control device hw:1
Tue Jan 24 20:48:02 2012: configuring for 48000Hz, period = 1024 frames (21.3 ms), buffer = 2 periods
Tue Jan 24 20:48:02 2012: ALSA: final selected sample format for capture: 24bit little-endian
Tue Jan 24 20:48:02 2012: ALSA: use 2 periods for capture
Tue Jan 24 20:48:02 2012: ALSA: final selected sample format for playback: 24bit little-endian
Tue Jan 24 20:48:02 2012: ALSA: use 2 periods for playback
Tue Jan 24 20:48:02 2012: e[1me[31mERROR: ALSA: cannot set hardware parameters for playbacke[0m
Tue Jan 24 20:48:02 2012: e[1me[31mERROR: ALSA: cannot configure playback channele[0m
Tue Jan 24 20:48:02 2012: e[1me[31mERROR: Cannot initialize drivere[0m
Tue Jan 24 20:48:02 2012: e[1me[31mERROR: JackServer::Open() failed with -1e[0m
Tue Jan 24 20:48:02 2012: e[1me[31mERROR: Failed to open servere[0m<\code>

Everything else seems to be fine:

$ arecord -l && aplay -l
**** List of CAPTURE Hardware Devices ****
card 0: Intel [HDA Intel], device 0: STAC92xx Analog [STAC92xx Analog]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: USX2Y [TASCAM US-X2Y], device 0: US-X2Y Audio [US-X2Y Audio #0]
Subdevices: 1/1
Subdevice #0: subdevice #0
**** List of PLAYBACK Hardware Devices ****
card 0: Intel [HDA Intel], device 0: STAC92xx Analog [STAC92xx Analog]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: USX2Y [TASCAM US-X2Y], device 0: US-X2Y Audio [US-X2Y Audio #0]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: NVidia [HDA NVidia], device 3: HDMI 0 [HDMI 0]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: NVidia [HDA NVidia], device 7: HDMI 0 [HDMI 0]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: NVidia [HDA NVidia], device 8: HDMI 0 [HDMI 0]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: NVidia [HDA NVidia], device 9: HDMI 0 [HDMI 0]
Subdevices: 1/1
Subdevice #0: subdevice #0<\code>

$ cat /proc/asound/cards
0 [Intel ]: HDA-Intel - HDA Intel
HDA Intel at 0xe9660000 irq 49
1 [USX2Y ]: USB US-X2Y - TASCAM US-X2Y
TASCAM US-X2Y (1604:8007 if 0 at 002/008)
2 [NVidia ]: HDA-Intel - HDA NVidia
HDA NVidia at 0xe3080000 irq 16<\code>

Any ideas?

Stefan

Did you load the firmware? (Install “alsa-firmware-loaders” package and run “usx2yloader”)

Also if it is a USB device, try using 3 periods instead of 2.

Seablade

@ pablo: Yes, I installed the alsa firmware and ran

‘sudo usx2yloader’

After that the lights of the US-122 turn on, but as shown above, QjackCtl will not start.

@ seablade: I tried it with 3 periods, but no changes…

Stefan

Does it work in “capture only” mode and “playback only” mode? What is the output of "lspci |grep -i usb’ ?

Pablo,

~$ lspci |grep -i usb
00:1a.0 USB Controller: Intel Corporation 5 Series/3400 Series Chipset USB2 Enhanced Host Controller (rev 05)
00:1d.0 USB Controller: Intel Corporation 5 Series/3400 Series Chipset USB2 Enhanced Host Controller (rev 05)<\code>

“capture only” or “playback only” mode does not work as well. I still get the same error-messages from QjackCtl that start with the line “31mERROR: Failed to acquire device name : Audio2 error : Input/output error”

I think you need a more recent kernel than the one from US 11.10. In any case, I don’t know if it is an alsa driver problem, a jack2 problem or a linux ehci module problem, or some combination(s) of your hardware and them. I suggest you should ask the experts at IRC or mailing lists (#jack @ irc.freenode.net, alsa-users ml, …).

Pablo, thank you very much for this information. I will try and check your suggestions. As soon as I have some news I will post them.