[pulseaudio-discuss] main.c: daemon startup failed.
tanuk at iki.fi
Sun Apr 13 14:03:49 PDT 2008
Hi, Sean! I hope you don't mind me correcting some
inaccuracies in your mail :)
On Sun, Apr 13, 2008 at 01:07:39PM -0400, Sean McNamara wrote:
> When you start PA with --daemonize=true (the default
> in /etc/pulse/daemon.conf),
The default is actually "daemonize = no" in daemon.conf. But
maybe your distro has decided to modify the default.
> If you want
> to see what's going on for a single console invocation of PA, you can
> pulseaudio -vvvv --daemonize=false
> It will then output all the debugging info to the console. The first v
> is for errors; the second, warnings; the third, notices; the fourth,
> debugging. Sometimes two v's isn't enough to get the full picture.
Two v's are enough to get the debug output. Without any v's
warnings and errors are shown.
> > Here are the messages that get logged when I try starting the server:
> > Apr 13 18:27:52 lily pulseaudio: main.c: setrlimit(RLIMIT_NICE, (31, 31)) failed: Operation not permitted
> > Apr 13 18:27:52 lily pulseaudio: main.c: setrlimit(RLIMIT_RTPRIO, (9, 9)) failed: Operation not permitted
> These two calls are PA's attempt to get real-time scheduling permission.
Those two calls are PA's attempt to set a couple of resource
limits, but at that point pulseaudio has changed the user to
"pulse", and it doesn't have the permissions to modify the
limits. This feels like a bug, and I think the rlimits
should not be read from a user-modifiable file. That would
make it possible to set the limits at an earlier stage
(hmm... I suspect that it wouldn't help with system-wide
mode after all, unless the limits can somehow survive the
The error about nice doesn't mean anything, because at this
point setting the nice value of the process has already
The error about rtprio means that pulseaudio won't be able
to use real-time scheduling (that's different thing than
> There are several reasons why this may not work (no PolicyKit, incorrect
> PolicyKit configuration, users not belonging to the right groups, etc.),
> but these errors are not fatal. The only surefire way to get realtime
> permissions regardless of system configuration is to start PA as root
> with --system=false.
That might work, but pulseaudio isn't meant to be run as
root. When running as a per-user daemon, all it takes to
enable real-time scheduling is to put the user to pulse-rt
group (and make sure the pulseaudio executable is suid root,
I think there was some distro that didn't have that by
default). And of course real-time scheduling has to be
enabled in daemon.conf. I don't know if PolicyKit will
change something about this.
Another thing that I don't know is how to enable real-time
scheduling in system-wide daemon. Maybe configuring the
rtprio resource limit for user "pulse" in
/etc/security/limits.conf could work.
The rest of the mail was good advice.
More information about the pulseaudio-discuss