Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 5 of 5
  1. #1
    Member
    Join Date
    Jan 2005
    Posts
    100

    Default Useful information

    I'm not sure how useful this will be to you, but for me it was part of my 5 month nightmare... which nearly led me to buying a new top spec server for £1000+ when it wasnt needed

    Basically i run a very very busy website, which uses a lot of MYSQL and has a lot of downloads... Now when their were a lot of users online pages on the server could take as long as 15 seconds to load.. i began tweakin MYSQL and APACHE confs to improve performance... Didnt work

    i invesigated hardware, again no really problem...

    Finally i came to the conclusion it was MYSQL and disk access time.. so i bought a SCSI drive 15K... their was slight improvement, but only by an extra few seconds..

    In the end, it turned out to be CLUTTERED LOG FILES !!

    Now by default apache will log every HTTP request into a single file located in DOMLOGS dir... my site was that busy that over time that log file had acumulated to 2.5GIG, so in other words, ever click, ever request made, the server had to open that hurendous file, dump a line of data into it, and close

    imagine that happening 1000 times a second, on top of all the other processes!

    The trick was, it doesnt really effect HARDWARE performance, so TOP etc produced no noticeable results.. !

    I have no disabled all logs and the server runs as any other would, regardless of peaks !!

    I just thought this was really interesting, and just goes to show that even the biggest problem with the most amount of research can have even the simplest solutions

    And to any of you who had logs enabled, you may want to check the size of them...

    du -sh * |grepM

    run that command in the domlogs DIR and see what you get

    or in my case... du -sh * |grepG !!

  2. #2
    Member
    Join Date
    Nov 2005
    Posts
    125

    Default

    As you said 'Useful Information'.... It is quite funny as well!

    One question, I'm not good with decoding these commands...

    Would the command be exactly like that? Or does the star change to something for each system?

  3. #3
    Member
    Join Date
    Aug 2004
    Posts
    22

    Default

    ---------------------------
    du -csh * |grep M

    du -csh * |grep G
    --------------------------

  4. #4
    Member
    Join Date
    Jan 2005
    Posts
    100

    Default

    Quote Originally Posted by FlamingHostCEO
    As you said 'Useful Information'.... It is quite funny as well!

    One question, I'm not good with decoding these commands...

    Would the command be exactly like that? Or does the star change to something for each system?
    the star is a WILD CARD... basically means search for all files, not a specific one

    do this in SSH

    CD /usr/local/apache/domlogs
    du -sh * |grepM

  5. #5
    Member
    Join Date
    May 2003
    Posts
    46

    Default

    Sorry for bringing up an old thread, but it was relavent.

    What if the domlogs (log files) were put on a drive other than the main drive that MYSQL uses? Like the backup drive? I have thought about trying that. The 2GB limit is a well known problem for linux/cpanel that causes apache to slow to a crawl.

    -vissa

Similar Threads & Tags
Similar threads

  1. Need some information
    By cnelindia in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 12-04-2006, 12:35 AM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube