apache is going really slow (and restarting it is the only thing that helps)

Discussion in 'Apache' started by steve51184, Feb 3, 2010.

  1. #1
    hey all i've been having some problems the last few months with my server/apache getting really slow (pages loading slow) and the only way i can fix it is to restart apache which is quite annoying and is not fixing the problem but it gets to the point where pages are almost not loading so i have to keep restarting apache but after 2mins it'll be slow again and once again i'll have to restart apache

    and here's my apache2.conf

    right back to the problem i first thought it was some kind of DOS/DDOS attack so i ran the following commands:

    the first shows a bunch of ip's and there connections but there's nothing to weird as there is only a few ip's that have over 20-30 with the rest having very few

    the second command shows the total connections and again nothing to odd about the number (150-250 ish)

    the third is for SYN but that's always been low on testing it like 1-10

    i think all this is quite normal (although i might be wrong) so i'm now quite stumped as to what the problem is and how to go about fixing it

    server specs/info:

    amd dual core 2.5ghz, 4gb ram, 2x 300gb hard drives etc

    ubuntu 8.10 server (dedicated) with apache2-prefork/php5/mysql, webmin/ispconfig

    please advise thanks

    note: i forgot to say that memory usage is a little higher then normal (500mb-700mb compared to 250mb-300mb - but goes back to normal after restarting apache) and the load is also a little high but always under 1 (also note my server is on a 100mbits port and i can easily push 100mbits 24/7 with no problems at all so it's not bandwidth)
     
    steve51184, Feb 3, 2010 IP
  2. rathin

    rathin Peon

    Messages:
    1,377
    Likes Received:
    9
    Best Answers:
    0
    Trophy Points:
    0
    #2
    what your maxclient value?
     
    rathin, Feb 4, 2010 IP
  3. steve51184

    steve51184 Peon

    Messages:
    4
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    maxclient value = 150
     
    steve51184, Feb 4, 2010 IP
  4. hostechsupport

    hostechsupport Well-Known Member

    Messages:
    413
    Likes Received:
    23
    Best Answers:
    7
    Trophy Points:
    138
    #4
    Hello,

    Need to compile apache . Do you have cPanel installed ?
     
    hostechsupport, Feb 4, 2010 IP
  5. steve51184

    steve51184 Peon

    Messages:
    4
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #5
    why would i need to install apache? and no i don't use cpanel i use webmin/ssh
     
    steve51184, Feb 4, 2010 IP
  6. rathin

    rathin Peon

    Messages:
    1,377
    Likes Received:
    9
    Best Answers:
    0
    Trophy Points:
    0
    #6
    just change the vlaue to 200 or 250 and the restart the apache and check it

    it may work for you some time
     
    rathin, Feb 5, 2010 IP
  7. steve51184

    steve51184 Peon

    Messages:
    4
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #7
    i've only just changed it from a higher value which helped so i'm not making it higher :p
     
    steve51184, Feb 5, 2010 IP
  8. GMC

    GMC Member

    Messages:
    99
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    45
    #8
    I have been battling this for the last couple of months as well

    I have pushed my max clients to 1000 and it hasnt helped

    I have tried nginx (it didnt work for me - but it might for you)

    I am wondering if Apache can process more than one request at a time - I have 900 tasks in the list - processing 1 - 899 sleeping - sever load is under 1 - memory use is OK, CPUs are 98% idle, and yet I have page load issues and a very slow site

    I hope someone can help you - because I bet it will help me

    Good Lucl
     
    GMC, Feb 6, 2010 IP