How to get ALSA to create PCM devices without X11 login?

Asked by Don Geddis

Ubuntu 11.04. Boot machine. SSH from outside. "aplay -l" reveals no sound card(s). "aplay -L" has only null device.

On desktop, log in (to same account). Suddenly, "aplay -l" (correctly) reveals two sound cards, and "aplay -L" offers loads of PCM devices.

Log out on desktop. Sound cards and PCM devices once again disappear from ALSA.

I want to use sound, when not logged in to the desktop (e.g., as a server). How can I force ALSA to create the PCM devices via a shell, that automatically get created during the X login?

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu alsa-driver Edit question
Assignee:
No assignee Edit question
Solved by:
Don Geddis
Solved:
Last query:
Last reply:
Revision history for this message
Don Geddis (don-geddis) said :
#1

FYI, this is the same as question #162266, but with a better title and description (now that I know more). I can see how to link to "bugs" or "FAQs" ... not sure how to link to another "question". Here's the URL:
https://answers.launchpad.net/ubuntu/+source/alsa-driver/+question/162266

Revision history for this message
Don Geddis (don-geddis) said :
#2

I solved my problem (as noted in answer 162266 above).

I needed to add my own username to the "audio" group in /etc/group.

I don't know why this wasn't already done automatically, or why nobody else had this problem, or why logging in the X11 console seems to have overcome the problem.

But at least the problem is solved now.