Bug 490040 - PA sticks to dead session bus
PA sticks to dead session bus
Product: Fedora
Classification: Fedora
Component: pulseaudio (Show other bugs)
All Linux
low Severity medium
: ---
: ---
Assigned To: Lennart Poettering
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2009-03-12 18:38 EDT by antonio montagnani
Modified: 2009-04-10 10:52 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2009-04-10 10:52:38 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
First user log (13.66 KB, text/plain)
2009-03-19 13:56 EDT, antonio montagnani
no flags Details
Same user logs out and logs in (13.09 KB, text/plain)
2009-03-19 13:58 EDT, antonio montagnani
no flags Details
.xsession-errors (1.09 KB, text/plain)
2009-03-30 15:58 EDT, antonio montagnani
no flags Details
in /var/log/messages (704 bytes, text/plain)
2009-03-30 15:59 EDT, antonio montagnani
no flags Details
Pulseaudio is working at first login (16.56 KB, text/plain)
2009-03-31 16:45 EDT, antonio montagnani
no flags Details
Pulseaudio is not working at next login (13.09 KB, text/plain)
2009-03-31 16:48 EDT, antonio montagnani
no flags Details
var/log/messages (90.77 KB, text/plain)
2009-04-01 02:02 EDT, antonio montagnani
no flags Details

  None (edit)
Description antonio montagnani 2009-03-12 18:38:12 EDT
Description of problem:
if I logout and I start a new session, pulseaudio is not working any longer (see #481685 closed for F10) 

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1.Boot (and pulseaudio is working)
2.Logout and login
3.Start any multimedia application and you will not get sound (actually you don't get even the login system sound)
4. issue pulseaudio -k and you will get back audio
Actual results:
No sound if you don't issue a pulseaudio -k

Expected results:
it should work

Additional info:
runnin Nvidia card with nv or nouveau driver
Comment 1 Adam Williamson 2009-03-13 13:39:45 EDT
This bug has been triaged

Fedora Bugzappers volunteer triage team
Comment 2 antonio montagnani 2009-03-15 05:50:23 EDT
additional info

If I am logged as UserA and I logout and I login as UserB I have pulseaudio working, when I log out from UserB and I re-login as UserA pulseaudio is not working.

It seems that only first session on any User make pulseaudio work (not totally sure..)
Comment 3 Lennart Poettering 2009-03-19 07:15:27 EDT
Is PulseAudio even running in the second session? What does "pactl list" print?
Comment 4 antonio montagnani 2009-03-19 13:56:08 EDT
Created attachment 335895 [details]
First user log

pactl list when logged as A first time
Comment 5 antonio montagnani 2009-03-19 13:58:12 EDT
Created attachment 335897 [details]
Same user logs out and logs in

user A logs out then logs in, no audio is running unless pulseaudio -k is issued.

This is before issuing pulseaudio -k
Comment 6 antonio montagnani 2009-03-19 14:02:20 EDT
differences start at line 285, furthermore pa1 is longer than pa2!!!

I am not an expert at all, but I assume that the two files should be similar...
Comment 7 antonio montagnani 2009-03-29 05:58:04 EDT
On a different system everything is running fine.
Comment 8 Lennart Poettering 2009-03-30 10:29:56 EDT
Sorry, unless I am stupid those two files are completely identical.

Also, please include the contents of ~/.xession-errors and everything from syslog that is related to PA here.
Comment 9 antonio montagnani 2009-03-30 10:52:43 EDT
I will send also that files...when I have my hands on that machine.

Anyway, the two files are different, at least on the client numbers at lines 285 and afterwards and at the end:

		output-analog-stereo+input-analog-stereo: Output Analog Stereo + Input Analog Stereo (sinks: 1, sources: 1, priority. 81010)
		output-analog-stereo: Output Analog Stereo (sinks: 1, sources: 0, priority. 51000)
		output-iec958-stereo+input-analog-stereo: Output Digital Stereo (IEC958) + Input Analog Stereo (sinks: 1, sources: 1, priority. 80510)
		output-iec958-stereo: Output Digital Stereo (IEC958) (sinks: 1, sources: 0, priority. 50500)
		output-analog-surround-40+input-analog-stereo: Output Analog Surround 4.0 + Input Analog Stereo (sinks: 1, sources: 1, priority. 30710)
		output-analog-surround-40: Output Analog Surround 4.0 (sinks: 1, sources: 0, priority. 700)
		output-analog-surround-41+input-analog-stereo: Output Analog Surround 4.1 + Input Analog Stereo (sinks: 1, sources: 1, priority. 30710)
		output-analog-surround-41: Output Analog Surround 4.1 (sinks: 1, sources: 0, priority. 700)
		output-analog-surround-50+input-analog-stereo: Output Analog Surround 5.0 + Input Analog Stereo (sinks: 1, sources: 1, priority. 30710)
		output-analog-surround-50: Output Analog Surround 5.0 (sinks: 1, sources: 0, priority. 700)
		output-analog-surround-51+input-analog-stereo: Output Analog Surround 5.1 + Input Analog Stereo (sinks: 1, sources: 1, priority. 30810)
		output-analog-surround-51: Output Analog Surround 5.1 (sinks: 1, sources: 0, priority. 800)
		input-analog-stereo: Input Analog Stereo (sinks: 0, sources: 1, priority. 30010)
		off: Off (sinks: 0, sources: 0, priority. 0)
	Profilo attivo: output-analog-stereo+input-analog-stereo

These lines are missing on the second attachment (the non working file).

Tnx for help
Comment 10 antonio montagnani 2009-03-30 15:58:29 EDT
Created attachment 337241 [details]

.xsession-errors after logout and login as same user...with no sound
Comment 11 antonio montagnani 2009-03-30 15:59:40 EDT
Created attachment 337242 [details]
in /var/log/messages

relevant part (Pulseaudio messages) after logout and login
Comment 12 Lennart Poettering 2009-03-30 18:10:39 EDT
There's something wrong with your D-Bus installation as it seems since PA cannot connect to your D-Bus server.
Comment 13 antonio montagnani 2009-03-30 18:48:39 EDT
anything I can do to debug my D-bus installation???
Shall I file a bug against D-bus???
Comment 14 antonio montagnani 2009-03-31 09:07:36 EDT
I issued a pulseaudio -k before logout and I logged in again as same user and sound is o.k.

I am not an expert, but I am not sure that it is connected to D-bus....It seems that is connected to management of tasks at logout.
Just an idea....a shot in the dark...
Comment 15 Lennart Poettering 2009-03-31 10:40:26 EDT
reserve-wrap.c: Unable to contact D-Bus session bus: org.freedesktop.DBus.Error.NoServer: Failed to connect to socket /tmp/dbus-j5Bx5XidBz: Connessione rifiutata

That tells me that the D-Bus session bus is not around. And that's a bug somewhere else.
Comment 16 antonio montagnani 2009-03-31 11:27:30 EDT
shall we point the bug to another component??
Comment 17 Lennart Poettering 2009-03-31 11:56:25 EDT

Are you running anything in a non-default way? i.e. you are not using KDE or something like that? You are not trying to use PA's system-wide mode, are you?
Comment 18 antonio montagnani 2009-03-31 12:38:34 EDT
I am running Gnome.

It is a standard installation, actually it is a F9, that became F10 and then rawhide.
I am using snd_intel8x0.

I think that nothing is running in a non default-way...
I inserted only the tsched=0 option and 

default-fragments = 8
default-fragment-size-msec = 5 in daemon.conf in /etc/pulse

No, I am not running PA in system-wide mode.
Comment 19 antonio montagnani 2009-03-31 12:48:30 EDT

for example I log in as A then I logout and I login as B and then I logout and I login as A, sound is working fine.

If I login as A and I logout and then I login again as A, I do not have sound.
Sound comes back if I logout and I login as a different user...
Comment 20 Lennart Poettering 2009-03-31 13:59:53 EDT
Could you please edit default.pa and set log-level to debug? Then retry and get me the outputs from syslog.
Comment 21 Lennart Poettering 2009-03-31 14:04:29 EDT
Oh, and the to initial logs are still mostly the same. They show differences in the connected clients. But that's it. I see no hint that the profile list was any different. Are you sure you attached the right files?
Comment 22 antonio montagnani 2009-03-31 16:45:25 EDT
Created attachment 337406 [details]
Pulseaudio is working at first login

I changed level-debug in /pulse/daemon.conf
Comment 23 antonio montagnani 2009-03-31 16:48:40 EDT
Created attachment 337407 [details]
Pulseaudio is not working at next login

Files are different: 481 lines vs 383.

Furthermore I note that sinks or Sorgente change status from Idle or running to Suspended.

Any additional test I can run???
Comment 24 Lennart Poettering 2009-03-31 18:02:23 EDT
uh, the log level only has an effect on the logs. i..e what appears in syslog. pactl output is not influenced by it.

Please provide me with the syslog output when pa starts up and it doesn't work for you, with log-level set to debug.
Comment 25 antonio montagnani 2009-04-01 02:02:03 EDT
Created attachment 337442 [details]

after booting, I logged in as user A, sound system could be heard, immediately logged out and relogged as user A, no sound.

The full /var/log/messages since  booting is attached
Comment 26 antonio montagnani 2009-04-02 17:39:34 EDT
I updated to pulseaudio-0.9.15-8.test7.fc11.i586 and problem seems to be solved ...Tomorrow I will check if this bug can be closed, too late now for testing.

Tnx Lennart!!!!!!
Comment 27 Lennart Poettering 2009-04-03 11:57:44 EDT
Hmmm, I am pretty sure this is not fixed.

I think I mostly understand what's going on: When you relogin PA stays around since it is a per-user, not a per-session daemon. It will usually exist after a 5s of idle. Now the problem is that it tries to do device reservation on the session bus. Since it got started from the first session it still tries to connect to the bus of that first session even when it is used by the second -- that bus is dead at that time and PA cannot do device reservation. Dang!

Not sure how to fix this. But at least I understand what's going on.
Comment 28 Lennart Poettering 2009-04-10 10:52:38 EDT
Should fixed in pulseaudio-0.9.15-9.test8.fc11

Note You need to log in before you can comment on or make changes to this bug.