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.

How to Optimized Apache

Discussion in 'EasyApache' started by neo4242002, Sep 27, 2005.

  1. neo4242002

    neo4242002 Well-Known Member

    Joined:
    Jun 28, 2005
    Messages:
    119
    Likes Received:
    0
    Trophy Points:
    16
    Hi.. I am running on cpanel, Apache/1.3.33 server with following hardware

    Processor 2.4 Ghz Super Celeron
    DDR Memory 1024mb
    Hard drive 80gb
    Bandwidth 1200gb

    I have a one site, which consume lots of traffic on my server.

    1. how do I optimized my server to handle 2000 visitors simultaneous ( I have seen my apache server get restart restart if more than 1400 visitors access this site)

    Here is one instance my apache got failed

    Code:
     Current Time: Tuesday, 27-Sep-2005 12:41:15 BST              
       Restart Time: Tuesday, 27-Sep-2005 12:04:31 BST              
       Parent Server Generation: 0
       Server uptime: 36 minutes 44 seconds
       Total accesses: 93033 - Total Traffic: 432.7 MB              <<<<<---- Check that 432M in 36mins. -->>>>
       CPU Usage: u325.25 s76.86 cu.51 cs.38 - 18.3% CPU load       
       42.2 requests/sec - 201.1 kB/second - 4877 B/request         
       15 requests currently being processed, 33 idle servers   
    2. do I need to upgrade my hardware? In that case what exactly I need to do

    3. Is there any tool to detect apaches stress (is that how you detect the apaches performance right?)

    4. is there any script to alert me when this site exceed x amount of traffic before entire apache get restart?

    5. how do I find if somebody is looting this site/ my server traffics?

    Can somebody help me please?
     
  2. Franzh

    Franzh Member

    Joined:
    Dec 16, 2004
    Messages:
    9
    Likes Received:
    0
    Trophy Points:
    1
    1 Are you using PHP? The scripts are normally compiled every time they are being called. Using software like eaccelerator or apc creates a cached compiled version which loads significantly faster with less CPU load.

    2 Depends on your answer on question 1. Try running top from the shell and see how much memory is being used/swapped. If a lot of memory is being swapped some extra memory would certainly improve things.

    3 Not sure what you meant. Using top in Linux shell shows the CPU load and how much resources every process use. For benchmarking there is a tool called ab which you will find in /usr/local/apache/bin/ or where your apache is installed.

    5 Here is a way to prevent deep linking of pictures. http://www.dennis.ca/weblog/archives/000409.php
     
Loading...

Share This Page