The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

VERY high CPU load !!! Please Help

Discussion in 'General Discussion' started by Giorgi, Apr 2, 2007.

  1. Giorgi

    Giorgi Member

    Joined:
    Mar 11, 2007
    Messages:
    23
    Likes Received:
    0
    Trophy Points:
    1
    hello gr8 ppl

    Here is my situation:

    I run:

    Fedora core 5 (32)
    CPU: Core Duo
    RAM: 4GB
    HDD: 6 units of HDD, SATA, RAIDed, 250GB each
    cPanel+WHM (trough reseller)

    I only run FILE HOSTING SCRIPT which is of course resource consuming script but I recieve very high CPU load, anything else seems to be normal.

    Additional info:

    WHM SERVICE INFO:

    Code:
    cpsrvd up  
    named (9.3.4) up  
    Server Load 22.64 (2 cpus)  
    Memory Used 24.8 %  
    Swap Used 0.00 %  
    Disk md1 (/)  65 %  
    Disk md0 (/boot)  4 % 
    APACHE CONFIG:

    Code:
    Timeout 200
    KeepAlive On
    MaxKeepAliveRequests 80
    KeepAliveTimeout 7
    MinSpareServers 5
    MaxSpareServers 10
    MaxClients 2000
    PHP.INI

    Code:
    max_execution_time = 360 
    max_input_time = 360	
    memory_limit = 32M 
    post_max_size = 2000M
    upload_max_filesize = 1000M
    default_socket_timeout = 360
    Thats all I modifed, everything else remains default.

    and this is my stats after TOP command:


    Code:
    Tasks: 291 total,   2 running, 289 sleeping,   0 stopped,   0 zombie
    Cpu(s): 55.6% us, 22.2% sy,  0.0% ni, 11.1% id,  0.0% wa,  0.0% hi, 11.1% si,
    Mem:   4126460k total,  3925804k used,   200656k free,    21728k buffers
    Swap: 41928952k total,      144k used, 41928808k free,  3118812k cached
     Unknown command - try 'h' for help
      PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
      451 root      10  -5     0    0    0 S    0  0.0  24:49.86 md1_raid5
    17152 mysql     15   0  122m  27m 3296 S    0  0.7   4:13.61 mysqld
      193 root      15   0     0    0    0 S    0  0.0   1:19.30 kswapd0
      462 root      15   0     0    0    0 S    0  0.0   1:01.54 kjournald
     1869 named     15   0 52804 8268 2100 S    0  0.2   0:43.19 named
     2724 root       0 -20     0    0    0 S    0  0.0   0:26.53 loop0
    23697 nobody    15   0 17240 7116 2336 S    0  0.2   0:13.90 httpd
    26459 nobody    15   0 17232 7108 2336 S    0  0.2   0:13.81 httpd
    23820 nobody    15   0 17156 7032 2336 S    0  0.2   0:12.97 httpd
    25516 nobody    15   0 17208 7100 2336 S    0  0.2   0:12.91 httpd
    23658 nobody    15   0 17184 6660 1920 S    0  0.2   0:12.00 httpd
    25601 nobody    15   0 17208 6684 1920 S    0  0.2   0:11.61 httpd
    26905 nobody    15   0 17212 6688 1920 S    0  0.2   0:11.41 httpd
    23656 nobody    15   0 17216 6692 1920 S    0  0.2   0:11.37 httpd
    23743 nobody    15   0 17212 6692 1924 S    0  0.2   0:10.94 httpd
    23826 nobody    15   0 17232 7112 2340 S    0  0.2   0:10.89 httpd
    26067 nobody    15   0 17136 6612 1920 S    0  0.2   0:10.68 httpd
    why I get so many sleeping taks? what does it means? what would you recommend?

    thank you in advance
     
  2. Giorgi

    Giorgi Member

    Joined:
    Mar 11, 2007
    Messages:
    23
    Likes Received:
    0
    Trophy Points:
    1
    Anybody? Plzzzzzzz Help
     
  3. ramprage

    ramprage Well-Known Member

    Joined:
    Jul 21, 2002
    Messages:
    667
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Canada
    If you have a RAID setup the array might be rebuilding.

    451 root 10 -5 0 0 0 S 0 0.0 24:49.86 md1_raid5

    Have you checked if you're getting a DDoS attack?
     
  4. Giorgi

    Giorgi Member

    Joined:
    Mar 11, 2007
    Messages:
    23
    Likes Received:
    0
    Trophy Points:
    1
    Tnx for replay

    1. I dont know, what is raid rebuilding? Tnx

    2. How can I check it? When I disable Apache load drops to 0.1 and when I turn it on it sudenlly shifts to 20-30

    any more suggestions?

    Thank you in advance
     
  5. mohit

    mohit Well-Known Member

    Joined:
    Jul 12, 2005
    Messages:
    553
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Sticky On Internet
    check what apache is serving......

    hi,
    if only apache is causing loads, you should see whats being served from it,
    either from ssh or from root whm--> Apache Status will show you what requests are being served....

    see ya,
    mohit
     
  6. Giorgi

    Giorgi Member

    Joined:
    Mar 11, 2007
    Messages:
    23
    Likes Received:
    0
    Trophy Points:
    1
    is there any way to detect ddos attack?
     
  7. brianoz

    brianoz Well-Known Member

    Joined:
    Mar 13, 2004
    Messages:
    1,146
    Likes Received:
    6
    Trophy Points:
    38
    Location:
    Melbourne, Australia
    cPanel Access Level:
    Root Administrator
    Not without knowing the basics of system admin - and since you don't know what RAID is, there's probably not much point us explaining it to you. For $40 - $50 you should be able to get someone to check out your system.

    If Raid is rebuilding, your system will be slow but load average also fairly low.
    If there's a DDOS happening, every aspect of your system will be slow and processes for one (or more) service(s) will be hogging the system. You should also see network I/O go through the roof.
     
  8. samuel77

    samuel77 Member

    Joined:
    Apr 6, 2007
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    Changing _nothing_ but installing

    Hi Friend,

    Changing _nothing_ but installing the i386 kernel image and the restricted modules package solves the problem on my hardware.
     
  9. Giorgi

    Giorgi Member

    Joined:
    Mar 11, 2007
    Messages:
    23
    Likes Received:
    0
    Trophy Points:
    1
    I know what is RAID, but I dont know what is RAID REBUILDING, if you cant explain then dont post, if I wanted to pay I would already had payed
     
  10. chirpy

    chirpy Well-Known Member

    Joined:
    Jun 15, 2002
    Messages:
    13,475
    Likes Received:
    20
    Trophy Points:
    38
    Location:
    Go on, have a guess
    Please don't be rude to people on the forum who are trying to help you, they do it in their own free time.

    If you don't know what a rebuilding RAID set is, you need to read up on how RAID sets work and what happens when members are being added or have failed in the set. That is what Brian is referring to.
     
  11. kevinm

    kevinm Member

    Joined:
    Feb 22, 2006
    Messages:
    19
    Likes Received:
    0
    Trophy Points:
    1
    vmstat
    iostat
    sysstat
    ps -faux ,

    are all your friends when you get a bound server .
     
  12. Murtaza_t

    Murtaza_t Well-Known Member

    Joined:
    Jan 24, 2005
    Messages:
    476
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Earth
    cPanel Access Level:
    Website Owner
    I can confirm the problem is not with the RAID as he has already said that the load goes down to 1 when he stops Apache, hence it is where it needs to be digged:

    run these commands to check your server:

    netstat -plan|grep :80|awk {'print $5'}|cut -d: -f 1|sort|uniq -c|sort -n

    this will list all the IPs that are using apache and will also show how many connection does that IP has.

    If the list is long then...(should be verrryyy Looooog) I am sorry to say.. you are HIT by DDOS ATTACT..

    You can use CSF (configserver's product) to deal with it...

    That is all can be said if you do not want to pay.. :rolleyes: LOL

    Edit:
    Noticed few spell checks.. ;)
     
    #12 Murtaza_t, Apr 10, 2007
    Last edited: Apr 10, 2007
  13. Parahosting

    Parahosting Well-Known Member

    Joined:
    Apr 6, 2007
    Messages:
    57
    Likes Received:
    0
    Trophy Points:
    6

    That really sounded like stupidity implying. That's like not understanding a math problem correctly, and because you don't understand it, the teacher won't help you.

    You could at LEAST direct him to Google search instead. Okay, I've experienced this problem before when I was on a hosting business long ago. First, check what processes are using up all that CPU load. If it's a process, try killing the process if it's not httpd and see if it fixes your problem.
     
  14. brianoz

    brianoz Well-Known Member

    Joined:
    Mar 13, 2004
    Messages:
    1,146
    Likes Received:
    6
    Trophy Points:
    38
    Location:
    Melbourne, Australia
    cPanel Access Level:
    Root Administrator
    Yes, sorry, that was a bit harsh and I do apologize; I simply meant it's not worth us trying to explain something here when it's much better explained elsewhere, but I could have said it in a much friendlier way!
     
  15. Parahosting

    Parahosting Well-Known Member

    Joined:
    Apr 6, 2007
    Messages:
    57
    Likes Received:
    0
    Trophy Points:
    6
    no harm done, no worries
     
  16. Giorgi

    Giorgi Member

    Joined:
    Mar 11, 2007
    Messages:
    23
    Likes Received:
    0
    Trophy Points:
    1

    I tried that command but list was not very long... I am really confused now, my users number rised and now my load average is 70-80... and sometimes even 100% or more... than I have to stop apache service and wait untill load drops to 0.2 and than start it again... cant explain why is this happening...
     
  17. Cristi4n

    Cristi4n Well-Known Member
    PartnerNOC

    Joined:
    Jul 2, 2006
    Messages:
    73
    Likes Received:
    0
    Trophy Points:
    6
    Check apache status from WHM, if you have access and see if there is a webpage accesed too much.
    Also check CPU/Memory/MySQL Usage from WHM.
    Set keepalive to off and see what happends.
     
    #17 Cristi4n, Apr 13, 2007
    Last edited: Apr 13, 2007
  18. Giorgi

    Giorgi Member

    Joined:
    Mar 11, 2007
    Messages:
    23
    Likes Received:
    0
    Trophy Points:
    1
    I noticed that Apache status is not connected with load, sometimes connections are more but load low and vice versa. I checked CPU/Memory/MySQL but I dont really know what to check there? I already set keepalive off, but load is still high.

    is there anyway to detect DDoS attack? or is there some really easy firewall to set-up? coz I am beginner.

    Thank you
     
Loading...

Share This Page