Sound does not work for different users if they belong to the audio group.
A workaround is to remove the users from the audio group. With this however simply managing individual device access based on standard group memberships stops working (regression).
Consolekit (like any kit handling device permissions/privilege escalation) needs to enable audio only for users belonging to audio group (when they are at the console), and leave it disabled for users not in the audio group.
Steps to reproduce the bugs:
1. Create 2 new users, user1 and user2 (to be sure you use Karmic default settings).
2. Restart. Login as one user, then double click on /usr/share/example-content/Aesop'\''s_Fables,_Volume_1_(Fable_1)_-_The_Fox_and_The_Grapes.spx
3. Switch to second user. The sound from the first user is still playing uninterrupted, even at gdm stage.
2. As the second user, double click on /usr/share/example-content/Ubuntu_Free_Culture_Showcase/SpiritOfUbuntu.ogv while the first user audio is still not finished.
Result: First user prevent any sound to be played as second user (with Totem, the video even doesn't start, but with other applications you can sometimes get the video but no audio). When the first user audio finishes to play, audio can be played as user2, but that would block audio for user1 if you switch back to its session.
Expected behavior: like in Jaunty and previous releases, sound from one user should stop playing when another session is active. In Jaunty and earlier, even VT had sound from one user when logged as this user, and from the other when logged as him.
Some audio applications on one session also prevent any sound to be played for the other user session even when they have nothing to play.
(Note: this is not a multi-seat setup, but a single seat computer with multiple user accounts.
See attached screenshots for details).
Other example: a first user has a session open, playing sound with Amarok (paused) on a Gnome desktop.
The second user chose "Switch user" in FUSA, then login. The new session doesn't have any sound, and the "Sound Preferences" window only lists "Dummy Output - Stereo" in the Output tab (Screenshot 1). In the hardware tab, nothing appears (Screenshot 2).
When the first user closes Amarok, the second user now has the hardware showing in the Hardware tab (Screenshot 3) but no sound, since the Profile is "Analog Stereo Duplex" (should be Analog Stereo Output"). When the user changes it to the right Profile, sounds works (see also Screenshot 4, compared to Screenshot 1 when no sound was played).
The second user can now play sound, for example a flash video.
Now though, the first user doesn't have any sound when coming back to its session (or more exactly, the only sound he can hear is the flash video being played in the second user's session, even though the users have switched. Any audio application the first user opens shows in Sound preferences>Applications, but doesn't output any sound, and moving the application individual sound sliders only affect the sound being played in session 2.
All that was handled properly in Jaunty and previous Ubuntu releases.
USER PID ACCESS COMMAND
/dev/snd/controlC0: paphro 9493 F.... pulseaudio
Card hw:0 'Intel'/'HDA Intel at 0xea300000 irq 22'
Mixer name : 'Realtek ALC889A'
Components : 'HDA:10ec0885,1458a002,00100101'
Controls : 38
Simple ctrls : 21
Date: Sun Sep 20 22:09:30 2009
DistroRelease: Ubuntu 9.10
Package: alsa-base 1.0.20+dfsg-1ubuntu4
ProcVersionSignature: Ubuntu 2.6.31-10.34-generic
Uname: Linux 2.6.31-10-generic i686