Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I noticed today that when making requests from our web server, things were rather slow. I started looking into it and I've found a load of root owned apache processes.

I don't know for sure that this is actually what's causing things to be slow, but none the less, it doesn't look good.

problem is, I don't know what to do from here? How do I find out why there are so many root processes? Could some recommend a set of tests? I've tried stracing a few of them, and they appear to be doing something, but the output of strace is beyond me.

root     30918  1.8  1.3  84284 52296 ?        Ss   14:11   0:01 /usr/sbin/apache2 -k restart
root     30919  0.0  1.1  84420 45612 ?        S    14:11   0:00 /usr/sbin/apache2 -k restart
root     30920  0.0  1.1  84420 45604 ?        S    14:11   0:00 /usr/sbin/apache2 -k restart
root     30921  0.0  1.1  84420 45612 ?        S    14:11   0:00 /usr/sbin/apache2 -k restart
root     30922  0.1  1.1  84420 45612 ?        S    14:11   0:00 /usr/sbin/apache2 -k restart
root     30923  0.0  1.1  84420 45612 ?        S    14:11   0:00 /usr/sbin/apache2 -k restart
www-data 30926  6.6  1.5 104964 61336 ?        S    14:12   0:03 /usr/sbin/apache2 -k restart
root     30930  0.1  1.1  84420 45616 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
root     30933  0.0  1.1  84420 45616 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
root     30935  0.0  1.1  84420 45616 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
root     30936  0.0  1.1  84420 45616 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
root     30937  0.0  1.1  84420 45616 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
root     30938  0.0  1.1  84420 45616 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
root     30961  0.0  1.1  84420 45612 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
root     30989  0.0  1.1  84420 45612 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
root     30990  0.0  1.1  84420 45612 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
root     31011  0.1  1.1  84420 45612 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
root     31013  0.1  1.1  84420 45612 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
root     31014  0.0  1.1  84420 45612 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
www-data 31175  2.5  1.5 104168 60524 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
www-data 31189  2.3  1.4 102360 58920 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
www-data 31190  1.5  1.4 101904 58356 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
www-data 31191  0.3  1.1  84556 46760 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
www-data 31192  1.4  1.4 101916 58384 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
www-data 31193  1.5  1.4 101916 58376 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart
root     31240  0.1  1.1  84420 45612 ?        S    14:12   0:00 /usr/sbin/apache2 -k restart

this is an example of the output from strace from one of the processes.

--- SIGCHLD (Child exited) @ 0 (0) ---
read(6, 0xff87f6ef, 1)                  = -1 EAGAIN (Resource temporarily unavailable)
getuid32()                              = 0
close(17)                               = 0
gettimeofday({1354109303, 670988}, NULL) = 0
semop(5668864, {{0, -1, SEM_UNDO}}, 1)  = 0
accept(4, {sa_family=AF_INET, sin_port=htons(48107), sin_addr=inet_addr("192.168.16.12")}, [16]) = 17
fcntl64(17, F_GETFD)                    = 0
fcntl64(17, F_SETFD, FD_CLOEXEC)        = 0
semop(5668864, {{0, 1, SEM_UNDO}}, 1)   = 0
clone(child_stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0xf74a2768) = 1949
waitpid(1949, [{WIFEXITED(s) && WEXITSTATUS(s) == 0}], 0) = 1949
--- SIGCHLD (Child exited) @ 0 (0) ---
read(6, 0xff87f6ef, 1)                  = -1 EAGAIN (Resource temporarily unavailable)
getuid32()                              = 0
close(17)                               = 0
gettimeofday({1354109305, 724358}, NULL) = 0
semop(5668864, {{0, -1, SEM_UNDO}}, 1)  = 0
accept(4, {sa_family=AF_INET, sin_port=htons(48132), sin_addr=inet_addr("192.168.16.12")}, [16]) = 17
fcntl64(17, F_GETFD)                    = 0
fcntl64(17, F_SETFD, FD_CLOEXEC)        = 0
semop(5668864, {{0, 1, SEM_UNDO}}, 1)   = 0
clone(child_stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0xf74a2768) = 1974
waitpid(1974, [{WIFEXITED(s) && WEXITSTATUS(s) == 0}], 0) = 1974
--- SIGCHLD (Child exited) @ 0 (0) ---
share|improve this question

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.