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.

Apache not behaving -- need advice!

Discussion in 'EasyApache' started by Crazy Pete, Jul 24, 2003.

  1. Crazy Pete

    Crazy Pete Well-Known Member

    Joined:
    May 16, 2003
    Messages:
    55
    Likes Received:
    0
    Trophy Points:
    6
    Hey guys, I really need some tips here because I'm pretty well stumped. Recently I asked my users if they thought the site was slow or not, and some of them replied that it was, takes a long time to load, etc. I've noticed myself that sometimes it seems to lag and hang at "Sending request to..." before it kicks in, usually I have to resubmit my request and it comes right in.

    I've got a P4 1.4G Tualatin server with 512MB of RAM and a 60G hard drive. It's only serving 10 sites, and really only 2 of them get any major traffic. What's odd is that of those two, one of them is pretty quick and responsive (and is just a vB), whereas the other site which is a vB and site is slower.

    Here are all the configs I can think of that would be relevant...

    PHP Config - http://www.expectedmiracles.com/forums/extras/phpinfo.php
    ----
    MySQL Info - http://www.expectedmiracles.com/mysql.php
    ----
    /etc/my.cnf -
    root@themiracle [/home/pete]# more /etc/my.cnf
    [mysqld]
    set-variable = max_connections=500
    thread_cache_size=50
    key_buffer=40M
    table_cache=384
    sort_buffer_size=768K
    read_buffer_size=512K
    read_rnd_buffer_size=512K
    thread_concurrency=2
    root@themiracle [/home/pete]#
    ----
    Current 'top' info -
    3:04pm up 33 days, 19:14, 1 user, load average: 0.06, 0.07, 0.08
    145 processes: 144 sleeping, 1 running, 0 zombie, 0 stopped
    CPU states: 0.0% user, 0.5% system, 0.0% nice, 99.4% idle
    Mem: 506048K av, 500152K used, 5896K free, 0K shrd, 128712K buff
    Swap: 522072K av, 44176K used, 477896K free 213088K cached
    ----
    Apache config -
    #-
    #Rlimit added by apachelimits.pl
    #-
    #RLimitMEM 72882858
    RLimitMEM 139492352
    RLimitCPU 120
    ##
    Timeout 300
    KeepAlive On
    MaxKeepAliveRequests 500
    KeepAliveTimeout 10
    MinSpareServers 8
    MaxSpareServers 20
    StartServers 5
    MaxClients 150
    MaxRequestsPerChild 0

    LoadModule rewrite_module libexec/mod_rewrite.so
    LoadModule php4_module libexec/libphp4.so
    LoadModule bwlimited_module libexec/mod_bwlimited.so
    LoadModule bytes_log_module libexec/mod_log_bytes.so
    LoadModule php4_module /usr/lib/apache/libphp4.so
    LoadModule gzip_module libexec/mod_gzip.so
    LoadModule bwprotect_module libexec/mod_bwprotect.so
    ----
    Someone had mentioned that the .htaccess file for the slower site might be causing problems (the faster site has no .htaccess file), so here's that, too...
    .htaccess file on slower site -
    RewriteEngine on
    RewriteCond %{HTTP_REFERER} !^ [NC]
    RewriteCond %{HTTP_REFERER} !^http://216.67.232.26(/).*$ [NC]
    RewriteCond %{HTTP_REFERER} !^http://(www\.)?expectedmiracles.com(/).*$ [NC]
    RewriteCond %{HTTP_REFERER} !^http://(www\.)?prp2.com(/).*$ [NC]
    RewriteCond %{HTTP_REFERER} !^http://(.*).mattnathanson.(.*)(/).*$ [NC]
    RewriteRule .*\.(gif|jpg|bmp|mp3)$ - [F,NC]
    ###STOP ROBOT DOWNLOADERS - BEGIN
    RewriteEngine on
    RewriteBase /
    RewriteCond %{HTTP_USER_AGENT} ^JetCar.* [NC]
    RewriteCond %{HTTP_USER_AGENT} ^FlashGet.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^Teleport.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^NetAnts.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^WebZIP.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^Offline.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^GetRight.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^Go!Zilla.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^GoZilla.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^WebReaper.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^ia_archiver.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^wget.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^HTTrack.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^WebStripper.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^WebCapture.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^Scooter-W3.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^WebCopier.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^FlashGe.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^Webdupe.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^NetAnts.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^Pockey.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^DiscoPump.* [NC,OR]
    RewriteCond %{HTTP_USER_AGENT} ^InternetNinja.* [NC,OR]
    RewriteRule .* - [F,L]
    ###STOP ROBOT DOWNLOADERS - END
    ---
    Apache <VirtualHost> entry on slower site -
    <VirtualHost 216.67.232.26>
    ServerAlias www.expectedmiracles.com expectedmiracles.com
    ServerAdmin webmaster@expectedmiracles.com
    DocumentRoot /home/pete/public_html
    BytesLog domlogs/expectedmiracles.com-bytes_log
    User pete
    Group pete
    ServerName www.expectedmiracles.com
    ServerAlias prp2.com www.prp2.com
    #CustomLog domlogs/expectedmiracles.com combined
    LogFormat "%h %v %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" \"%{Cookie}i\"" special
    CustomLog domlogs/expectedmiracles.com special
    ScriptAlias /cgi-bin/ /home/pete/public_html/cgi-bin/
    </VirtualHost>
    ---

    What can I look for as far as problems go? For some reason one site is very slow and it's really starting to bug me. Anything I should look for to change? I'd really appreciate any help, thanks! Also if there's any other info you people would want, please let me know.

    cPanel.net Support Ticket Number:
     
  2. cPanelNick

    cPanelNick Administrator
    Staff Member

    Joined:
    Mar 9, 2015
    Messages:
    3,426
    Likes Received:
    2
    Trophy Points:
    38
    cPanel Access Level:
    DataCenter Provider
    Not sure why you are loading php4 twice:

    try removing

    LoadModule php4_module /usr/lib/apache/libphp4.so

    cPanel.net Support Ticket Number:
     
  3. Crazy Pete

    Crazy Pete Well-Known Member

    Joined:
    May 16, 2003
    Messages:
    55
    Likes Received:
    0
    Trophy Points:
    6
    Ok I just did that, not sure if it'll do much though, usually when I started Apache it would tell me module php4 was already loaded and skip that one.

    cPanel.net Support Ticket Number:
     
Loading...

Share This Page