Ticket #784 (new defect)

Opened 2 years ago

Last modified 2 years ago

pulseaudio handles console logout badly

Reported by: mnk Owned by: lennart
Milestone: Component: daemon
Keywords: Cc:

Description

If I start a session, then A-C-F2 to console and login as the same user, when I logout from second session, daemon is terminated for both sessions.

pulseaudio is 0.9.21, with some of the git patches. Not sure what info will be required in this case.

Attachments

pulseaudio-fail.log (151.7 kB) - added by mnk 2 years ago.
daemon's log

Change History

Changed 2 years ago by coling

I cannot reproduce that here with a similarly up-to-date build (but not in F12)

Can you get a log file from the server while this happens? Are you sure that start-pulseaudio-x11 has been run and the daemon on the x11 session is not just timing out naturally? ("pacmd list-modules | grep x11" should tell you).

Changed 2 years ago by mnk

name: <module-x11-publish> name: <module-x11-cork-request>

It may matter, that I'm not using a display manager - it's 'startx'+'startx -- :1'. That runs ROX-Session, which in turn runs pulseaudio' desktop file. The log doesn't make much sense for me.

Changed 2 years ago by mnk

daemon's log

Changed 2 years ago by coling

Right so the module-x11-xsmp is not loaded, which means you are not running and X11 session manager. This means PA will naturally die off after a period of inactivity even if you are still running X.

I'm wondering if we should also prevent the idle timeout with information from consolekit (i.e. if CK says we have a session, then don't shut down). This would almost negate the need for xsmp....

It seems that at the end of the log, there is some error accessing some X11 stuff. I presume PA died at this stage? I'm not really sure where this error is, but you could try unloading the two x11 modules to see if this solves the problem. If possible try and isolate which of the two modules causes the problem.

Changed 2 years ago by mnk

Well, may be not loaded cause of '#' in default.pa - I forgot about that bit: at some point I was trying to make pulseaudio work in system mode and that didn't work at all, if that module was loaded before xserver was started.

Now, it's setup in a standard way. I'm thinking about removing that comment, but wouldn't that prevent daemon from working outside X ?

Changed 2 years ago by coling

No it's not meant to be loaded in default.pa, it's meant to be loaded by the start-pulseaudio-x11 script. Even then it'll only work if there is a session manager running.

The official version of default.pa has this commented out too. I should probably remove it from the file completely to avoid any confusion.

Changed 2 years ago by mnk

Correction: ROX-Session is indeed not considered X11 session manager by pulseaudio.

On unrelated note: a cosmetic detail, but IMHO, it would look better if the final output line of pacmd '>>> ' was either terminated by '\n' or not printed at all.

Changed 2 years ago by mnk

It seems that both of these modules are at fault: when neither is loaded, everything works fine, when it's just the cork, daemon seems to quit, but gets auto respawned, however if both are loaded, daemon not only goes down, but takes firefox down too (perhaps other clients too - firefox was the only client during tests).

Changed 2 years ago by mnk

So, yesterday I reminded myself about this bug and found today the missing bit about pam consolekit configuration.

Now, consolekit session is triggered by login, but pulseaudio with those two modules still terminates.

Could it be that those modules handle badly the case where one user is logged in more than once ?

Note: See TracTickets for help on using tickets.