This forum has been archived. All content is frozen. Please use KDE Discuss instead.

[SOLVED] A huge number of processes

Tags: None
(comma "," separated)
User avatar
igorsinkovec
Registered Member
Posts
5
Karma
0
OS

[SOLVED] A huge number of processes

Fri Sep 20, 2013 12:00 pm
Hi all,

I have a problem of a lot of "useless" processes running, in fact so many that I get the "Maximum number of clients reached" error when I try to start a new application. This prevents me from being able to work unless I kill the processes by hand or log out. Needless to say I don't want to log out and back in every day or to have to kill processes, not only because I can't be sure which of them I can kill safely.

Most of the running processes are kded4 (some of them zombie), kdeinit4 and dbus-daemon. The zombie kded4 processes always have a kded4 parent, who have a kdeinit4 parent, who again have a kdeinit4 parent, who again have a kded4 parent. Confusing. So, kded4 (zombie) -> kded4 -> kdeinit4 -> kdeinit4 -> kded4. If I kill the top parent kded4 process, all the children die with it. This is an approximate process count (I only have 10-15 windows open at any given time):

38 [kded4] <defunct>
78 /usr/bin/kdeinit4 --suicide
116 kdeinit4: kdeinit4 Running...
152 kdeinit4: klauncher [kdeinit] --fd=8
167 //bin/dbus-daemon --fork --print-pid 5 --print-address 7 --session
189 kdeinit4: kded4 [kdeinit]

Is there a way to find out how these processes are started and who is starting them? My guess is there is a script being run by cron leaving orphaned processes. I have a few of my own scripts run by cron that I use for administrative tasks, so that's a possibility.

Thank you for any suggestions.

Igor

Last edited by igorsinkovec on Sun Sep 22, 2013 11:05 am, edited 1 time in total.
User avatar
scummos
Global Moderator
Posts
1175
Karma
7
OS
As far as I know, the "Maximum number of clients reached" is an X11 error, and unrelated to the number of running processes. I think you can run "xrestop" and look at the "wins" (windows) column to find out which application has registered all those clients.

Cheers,
Sven


I'm working on the KDevelop IDE.
User avatar
igorsinkovec
Registered Member
Posts
5
Karma
0
OS
scummos wrote:As far as I know, the "Maximum number of clients reached" is an X11 error, and unrelated to the number of running processes.


I would agree if killing those processes didn't solve that error. It is true it's an X11 error, it's caused by X server running out of sockets - I think it has a hardcoded limit of 256 or something. But like I said, I'm sure it is related, because by killing just enough processes I'm able to start applications again.
User avatar
scummos
Global Moderator
Posts
1175
Karma
7
OS
Yes but you should blame the processes which allocate hundreds of windows, not those which allocate 1. Of course, killing those with 1 will also allow you to start more applications, but they are not the cause of the problem.


I'm working on the KDevelop IDE.
User avatar
igorsinkovec
Registered Member
Posts
5
Karma
0
OS
I found it. One of my scripts was responsible for it, calling dbus-launch every ten minutes :)


Bookmarks



Who is online

Registered users: Bing [Bot], daret, Google [Bot], Sogou [Bot]