Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

So I was wondering around the web, and cant seem to find any decent Treads trouble shooting guide. Ans at the same time my server spiked yo 3k threads. So maybe someone could give me some tips, or possible links where I could solve my problem.

I am running standart LAMP server.

Ok, so I got the spike of 3.00k threads from my munin status. At the same time the processes spiked up to a 2.2k. The average nr. of threads is 1.5k. The average nr. of sleeping processes is 1.3k. As well as that I check that I hade spikes in Swap, RAM-committed, ans MySQL Threads up to 700 threads ! Ok, so it probably means that some programmer did something interesting.

# ps aux | wc -l
1424
ps aux | grep apache  | wc -l
974
ps aux | grep mysql  | wc -l
3
ps aux | grep root  | wc -l
475

Now I understand the apache processes, I know i have to optimize it. But the root processes it something that really disturbs me as I am not sure what those processes are and google does not to really specify them either. So i did

ps aux | grep root

I got load of different processes:

[xfsconvertd/19]
[xfsdatad/19]
[xfslogd/19]
[ext4-dio-unwrit]
[kthrotld/15]
... etc ...

The thing thats weird is that most of them are sleeping:

ps aux | grep S | wc -l
1414

Now should I worry ? and maybe I should kill the sleeping processes ? If so, which one ? Or what steps should I take from stopping it happening again ?

share|improve this question
    
root processes are good! they keep your system running!! if they are sleeping that's good too. From your question you must be a newbie to the unix environments. I think you need to do some study.your website must be under a lot of load. There a lot of threads on server fault about troubleshooting this kind of problem....... you can strip the number of root processes running dowm and optomise you r kernel etc etc. But you need to know what your doing, and what you need. I'd say that's an advanced administrator level,but it can be done.Perhaps post your entire root processes and i'll take a look –  The Unix Janitor Mar 13 '12 at 16:43
    
Hi, cheers for a quick reply. paste.ubuntu.com/882057 here is the output of ps aux | grep root . Yes I am newbie. Kinda trying to learn by doing :) –  Katafalkas Mar 13 '12 at 17:09

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.