Page 1 of 2 12 LastLast
Results 1 to 10 of 17

Thread: Slow KDE-login possibly caused by rtkit-daemon failing to start

  1. #1

    Default Slow KDE-login possibly caused by rtkit-daemon failing to start

    Since about a week, I've been experiencing very slow logins. It takes about five minutes for the menu-bar to appear on the KDE desktop. This happend after a system update around a week ago (September 9).

    It seems like the login is trying to start rtkit-daemon, which consistently fails to start, with an error "eventfd(): Too many open files".
    I see this error repeated in the log a number of times, until it gives up starting rtkit-daemon and finally displays the desktop.

    I've tried to raise the max number of open files allowed, but that didn't make the error go away.
    Has anyone else been experiencing problems with slow logins or rtkit failing to start during the last week or so?

    Perhaps someone has any ideas of a workaround or bugfix?

  2. #2
    Join Date
    Sep 2008
    Posts
    2,997

    Default Re: Slow KDE-login possibly caused by rtkit-daemon failing to start

    most likely a pulse audio issue what the issue is who knows
    I'd say run an update and see if it fixes things
    Code:
    zypper up
    if not try removing the pulse audio config files
    Code:
    rm -rf ~/.config/pulse
    then reboot
    or try pavucontrol to fix things

  3. #3

    Default Re: Slow KDE-login possibly caused by rtkit-daemon failing to start

    Thanks for the hints.
    I've applied the latest updates, removed ~/.config/pulse (and also ~/.pulse and ~/.pulse-cookie), in fact, I've even tried logging in with a new and clean user.
    I also installed pavucontrol as you suggested.

    Unfortuantley it didn't help.

    This is what I see repeated in the syslog from rtkit:

    Code:
    2017-09-18T17:24:54.813518+02:00 linux-nm5f systemd[1]: Starting RealtimeKit Scheduling Policy Service...
    2017-09-18T17:24:54.872784+02:00 linux-nm5f dbus[1190]: [system] Successfully activated service 'org.freedesktop.RealtimeKit1'
    2017-09-18T17:24:54.873065+02:00 linux-nm5f rtkit-daemon[2939]: Successfully called chroot.
    2017-09-18T17:24:54.873341+02:00 linux-nm5f systemd[1]: Started RealtimeKit Scheduling Policy Service.
    2017-09-18T17:24:54.873526+02:00 linux-nm5f rtkit-daemon[2939]: Successfully dropped privileges.
    2017-09-18T17:24:54.873653+02:00 linux-nm5f rtkit-daemon[2939]: Successfully limited resources.
    2017-09-18T17:24:54.873820+02:00 linux-nm5f rtkit-daemon[2939]: eventfd() failed: Too many open files
    2017-09-18T17:24:54.873937+02:00 linux-nm5f rtkit-daemon[2939]: Demoting known real-time threads.
    2017-09-18T17:24:54.874049+02:00 linux-nm5f rtkit-daemon[2939]: Demoted 0 threads.
    2017-09-18T17:24:54.874761+02:00 linux-nm5f dbus[1190]: [system] Activating via systemd: service name='org.freedesktop.RealtimeKit1' 
    unit='rtkit-daemon.service'
    2017-09-18T17:24:54.875751+02:00 linux-nm5f systemd[1]: Started RealtimeKit Scheduling Policy Service.
    2017-09-18T17:24:54.901545+02:00 linux-nm5f systemd[1]: rtkit-daemon.service: Main process exited, code=exited, status=1/FAILURE
    2017-09-18T17:24:54.901881+02:00 linux-nm5f systemd[1]: rtkit-daemon.service: Unit entered failed state.
    2017-09-18T17:24:54.902052+02:00 linux-nm5f systemd[1]: rtkit-daemon.service: Failed with result 'exit-code'.
    2017-09-18T17:25:19.890794+02:00 linux-nm5f dbus[1190]: [system] Failed to activate service 'org.freedesktop.RealtimeKit1': timed out
    Before the updates last week, there were no rtkit-related errors in the syslog.

  4. #4

    Default Re: Slow KDE-login possibly caused by rtkit-daemon failing to start

    Quote Originally Posted by mrclrssn View Post
    It seems like the login is trying to start rtkit-daemon
    As indicated already, pulseaudio uses rtkit, and pulseaudio is started during login.

    I've tried to raise the max number of open files allowed, but that didn't make the error go away.
    And how exactly did you do that?

    Maybe you'd need to actually raise the allowed number of processes though (in /etc/security/limits.conf).
    I.e. try to raise the values in these two lines:
    Code:
    # harden against fork-bombs*               hard    nproc           1700
    
    *               soft    nproc           1200
    The nproc limits are quite low in Leap 42.3, and there already are bug reports about that.

    Has anyone else been experiencing problems with slow logins or rtkit failing to start during the last week or so?
    Works fine here.
    But if it is about the nproc limit, it likely depends on what else is started during login.
    If you keep applications running on logout, they will get restarted on login. And especially Chromium is notorious for using a lot of processes...

  5. #5

    Default Re: Slow KDE-login possibly caused by rtkit-daemon failing to start

    Quote Originally Posted by wolfi323 View Post
    As indicated already, pulseaudio uses rtkit, and pulseaudio is started during login.


    And how exactly did you do that?
    In /etc/security/limits.conf I've added:
    Code:
    *               hard    nofile          16384
    *               soft    nofile          16384
    But if it is about the nproc limit, it likely depends on what else is started during login.
    If you keep applications running on logout, they will get restarted on login. And especially Chromium is notorious for using a lot of processes...
    Thanks, I'll try that the next reboot. However I don't keep applications running on logout and I don't have any database servers or application servers running on this machine, so I don't expect much of a difference.

  6. #6

    Default Re: Slow KDE-login possibly caused by rtkit-daemon failing to start

    I'm also recently experiencing this problem on leap 42.2, i.e. getting
    rtkit-daemon[]: eventfd() failed: Too many open files
    on journalctl -u rtkit-daemon -l

    I fail to see, how increasing the processes limit will help for that error and doubt very much increasing nofiles in /etc/security/limits.conf will help either, as the log contains just a line above "Successfully limited resources.".

    In http://git.0pointer.net/rtkit.git/tree/rtkit-daemon.c there seems a coded limit of 50:
    { .id = RLIMIT_NOFILE, .name = "RLIMIT_NOFILE", .value = 50 }

    However as to why it suddenly needs more than this is beyond me...

    Thanks.

  7. #7

    Default Re: Slow KDE-login possibly caused by rtkit-daemon failing to start

    Quote Originally Posted by flinker View Post
    I'm also recently experiencing this problem on leap 42.2, i.e. getting
    rtkit-daemon[]: eventfd() failed: Too many open files
    on journalctl -u rtkit-daemon -l

    I fail to see, how increasing the processes limit will help for that error
    That was just a suggestion, because there are problems with the too low process limit in Leap.
    Many things in Linux are treated like files, so it might just be a misleading error message...

    Of course the actual problem might just as well be something else completely.

  8. #8
    Join Date
    Feb 2010
    Location
    Germany
    Posts
    4,552

    Default Re: Slow KDE-login possibly caused by rtkit-daemon failing to start

    Quote Originally Posted by flinker View Post
    I'm also recently experiencing this problem on leap 42.2,
    I'm also on Leap 42.2 here but, without any Realtime Kit issues:

    In systemd:
    Code:
    rtkit-daemon.service                    disabled
    (It's started by Pulse Audio when a user logs in.)
    Code:
     > systemctl status rtkit-daemon.service
    ● rtkit-daemon.service - RealtimeKit Scheduling Policy Service
       Loaded: loaded (/usr/lib/systemd/system/rtkit-daemon.service; disabled; vendor preset: disabled)
       Active: active (running) since Di 2017-09-19 08:16:41 CEST; 2h 58min ago
     Main PID: 4682 (rtkit-daemon)
        Tasks: 3 (limit: 512)
       CGroup: /system.slice/rtkit-daemon.service
               └─4682 /usr/lib/rtkit/rtkit-daemon
     >
    Systemd Journal -- this-boot:
    Code:
    Sep 19 08:16:41 xxx dbus[1167]: [system] Activating via systemd: service name='org.freedesktop.RealtimeKit1' unit='rtkit-daemon.service'
    Sep 19 08:16:41 xxx systemd[1]: Starting RealtimeKit Scheduling Policy Service...
    Sep 19 08:16:41 xxx dbus[1167]: [system] Successfully activated service 'org.freedesktop.RealtimeKit1'
    Sep 19 08:16:41 xxx systemd[1]: Started RealtimeKit Scheduling Policy Service.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Successfully called chroot.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Successfully dropped privileges.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Successfully limited resources.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Running.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Canary thread running.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Successfully made thread 4681 of process 4681 (/usr/bin/pulseaudio) owned by 'yy' high priority at nice level -11.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Supervising 1 threads of 1 processes of 1 users.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Watchdog thread running.
    Sep 19 08:16:41 xxx polkitd[2897]: Registered Authentication Agent for unix-session:4 (system bus name :1.39 [/usr/lib64/libexec/polkit-kde-authentication-agent-1], object path /org/kde/PolicyKit1/AuthenticationAgent, locale de_DE.UTF-8)
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Supervising 1 threads of 1 processes of 1 users.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Successfully made thread 4715 of process 4681 (/usr/bin/pulseaudio) owned by 'yy' RT at priority 5.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Supervising 2 threads of 1 processes of 1 users.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Supervising 2 threads of 1 processes of 1 users.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Successfully made thread 4726 of process 4681 (/usr/bin/pulseaudio) owned by 'yy' RT at priority 5.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Supervising 3 threads of 1 processes of 1 users.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Supervising 3 threads of 1 processes of 1 users.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Successfully made thread 4729 of process 4681 (/usr/bin/pulseaudio) owned by 'yy' RT at priority 5.
    Sep 19 08:16:41 xxx rtkit-daemon[4682]: Supervising 4 threads of 1 processes of 1 users.
    Vanilla Leap 42.2 -- Apache and Samba servers are running -- '/etc/security/limits.conf' only has the default "harden against fork-bombs"
    Code:
    *               hard    nproc           1700
    *               soft    nproc           1200
    root            hard    nproc           3000
    root            soft    nproc           1850

    Suggestion: check the user's '~/.cache/' directory and the user files in '/tmp/' and '/var/tmp/' -- there may be some extraneous files present from a previous crash or whatever.

  9. #9
    Join Date
    Feb 2010
    Location
    Germany
    Posts
    4,552

    Default Re: Slow KDE-login possibly caused by rtkit-daemon failing to start

    Quote Originally Posted by mrclrssn View Post
    I've tried to raise the max number of open files allowed, but that didn't make the error go away.
    Please post the (user) CLI output of 'ulimit' and 'ulimit -a'.
    On this vanilla Leap 42.3 Laptop -- no servers running and, the "rtkit-daemon" journal entries are the same as those for the Leap 42.2 system posted previously -- the outputs are:
    Code:
     > ulimit 
    unlimited
     > ulimit -a
    core file size          (blocks, -c) 0
    data seg size           (kbytes, -d) unlimited
    scheduling priority             (-e) 0
    file size               (blocks, -f) unlimited
    pending signals                 (-i) 28471
    max locked memory       (kbytes, -l) 64
    max memory size         (kbytes, -m) unlimited
    open files                      (-n) 1024
    pipe size            (512 bytes, -p) 8
    POSIX message queues     (bytes, -q) 819200
    real-time priority              (-r) 0
    stack size              (kbytes, -s) 8192
    cpu time               (seconds, -t) unlimited
    max user processes              (-u) 1200
    virtual memory          (kbytes, -v) unlimited
    file locks                      (-x) unlimited
     >

  10. #10

    Default Re: Slow KDE-login possibly caused by rtkit-daemon failing to start

    Just out of interest, I git cloned the RealtimeKit sources from http://git.0pointer.net/rtkit.git/tree/ and built it, then run the resulting executabe directly from the shell

    Code:
    2017-09-19T18:19:28.326658+02:00 linux-nm5f rtkit-daemon[12405]: Successfully called chroot.
    2017-09-19T18:19:28.327006+02:00 linux-nm5f rtkit-daemon[12405]: Successfully dropped privileges.
    2017-09-19T18:19:28.327244+02:00 linux-nm5f rtkit-daemon[12405]: Successfully limited resources.
    2017-09-19T18:19:28.327445+02:00 linux-nm5f rtkit-daemon[12405]: Running.
    2017-09-19T18:19:28.327644+02:00 linux-nm5f rtkit-daemon[12405]: Canary thread running.
    2017-09-19T18:19:28.327855+02:00 linux-nm5f rtkit-daemon[12405]: Watchdog thread running.
    No eventfd() crash.

    Then executing the old /usr/lib/rtkit/rtkit-daemon from the shell. Immediate crash:

    Code:
    2017-09-19T18:22:14.405969+02:00 linux-nm5f rtkit-daemon[12417]: Successfully called chroot.
    2017-09-19T18:22:14.406155+02:00 linux-nm5f rtkit-daemon[12417]: Successfully dropped privileges.
    2017-09-19T18:22:14.406266+02:00 linux-nm5f rtkit-daemon[12417]: Successfully limited resources.
    2017-09-19T18:22:14.406324+02:00 linux-nm5f rtkit-daemon[12417]: eventfd() failed: Too many open files
    2017-09-19T18:22:14.406349+02:00 linux-nm5f rtkit-daemon[12417]: Demoting known real-time threads.
    2017-09-19T18:22:14.406373+02:00 linux-nm5f rtkit-daemon[12417]: Demoted 0 threads.
    Interesting...

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •