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.

Server error 500 and packet loss

Discussion in 'General Discussion' started by InteractM, Sep 25, 2015.

  1. InteractM

    InteractM Well-Known Member

    Joined:
    Apr 2, 2013
    Messages:
    133
    Likes Received:
    1
    Trophy Points:
    18
    cPanel Access Level:
    Root Administrator
    Is there any dependence between packet loss and server error 500? I have checked Apache access logs for 500s and it looks like random occurrence without any major cause. Also I have noticed that outer switch was generating collisions which may have correlation to packet loss on that network. In most cases it looks like somebody got 500 and then reload page and page got loaded.

    Also all 500 errors aren't equal - how can I be more specific by analyzing access log?

    Thanks
     
  2. InteractM

    InteractM Well-Known Member

    Joined:
    Apr 2, 2013
    Messages:
    133
    Likes Received:
    1
    Trophy Points:
    18
    cPanel Access Level:
    Root Administrator
    What do I need to enable to stack trace those 500's errors?
     
  3. 24x7server

    24x7server Well-Known Member

    Joined:
    Apr 17, 2013
    Messages:
    1,146
    Likes Received:
    34
    Trophy Points:
    48
    Location:
    India
    cPanel Access Level:
    Root Administrator
    Hello,

    What error you getting in your Apache error logs file ?

    Does you own a vps or a dedicated server ?
     
  4. InteractM

    InteractM Well-Known Member

    Joined:
    Apr 2, 2013
    Messages:
    133
    Likes Received:
    1
    Trophy Points:
    18
    cPanel Access Level:
    Root Administrator
    It is a dedicated server

    An example Apache access log with 500 error:

    157.55.39.112 - - [25/Sep/2015:10:20:45 -0400] "GET /meet-the-staff-finance-administration-technology-ud-3173/ HTTP/1.1" 500 70432 "-" "Mozilla/5.0 (compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm)"​

    and related error from errors log:

    [Fri Sep 25 10:21:50 2015] [error] [client 157.55.39.112] zend_mm_heap corrupted
    [Fri Sep 25 10:21:50 2015] [error] [client 157.55.39.112] Premature end of script headers: index.php​

    but for that 500 error from access log there is no related line in an error:

    54.84.95.88 - - [25/Sep/2015:10:25:47 -0400] "GET / HTTP/1.1" 500 - "-" "webmon-webagent v1.3"​

    and I have a lot of them - no related error_log to pair. Most of them it looks like crawling bots or a monitoring service.
     
  5. Jcats

    Jcats Well-Known Member

    Joined:
    May 25, 2011
    Messages:
    275
    Likes Received:
    31
    Trophy Points:
    28
    Location:
    New Jersey
    cPanel Access Level:
    DataCenter Provider
    You could try this:

    http://stackoverflow.com/questions/2247977/what-does-zend-mm-heap-corrupted-mean

    But I would probably rebuild Apache / PHP running easyapache

    You can also check to see if it was possibly a memory related issue:

    # grep OOM /var/log/messages

    500 is a PHP related error so there are a lot of possibilities but 'zend_mm_heap corrupted' seems to be it which I personally haven't seen thinking back, so Google is going to be a good place to start if no one else has any ideas.

    Also, is the 'zend_mm_heap corrupted' consistent which each 500 error you see in the Apache error_log?

    # grep error /usr/local/apache/logs/error_log |grep -Ev 'File does not exist|script not found or unable'
     
  6. InteractM

    InteractM Well-Known Member

    Joined:
    Apr 2, 2013
    Messages:
    133
    Likes Received:
    1
    Trophy Points:
    18
    cPanel Access Level:
    Root Administrator
    I saw that and have enabled output_buffer in the php.ini


    Nothing there.

    I have read that 500's may be not only PHP related (that one should to return related errors in error_log but nothing there).

    Nope - as I have said most of them are crawlers with 500 errors :\
     
  7. Jcats

    Jcats Well-Known Member

    Joined:
    May 25, 2011
    Messages:
    275
    Likes Received:
    31
    Trophy Points:
    28
    Location:
    New Jersey
    cPanel Access Level:
    DataCenter Provider
    Weird, you don't have any mod_sec or .htaccess rules used to block bots maybe? I know it would in most cases throw 403's but I have seen 500/501 in some cases.
     
  8. InteractM

    InteractM Well-Known Member

    Joined:
    Apr 2, 2013
    Messages:
    133
    Likes Received:
    1
    Trophy Points:
    18
    cPanel Access Level:
    Root Administrator
    Not for my knowledge but I can compare other site on same server if has same problems with crawlers
     
  9. InteractM

    InteractM Well-Known Member

    Joined:
    Apr 2, 2013
    Messages:
    133
    Likes Received:
    1
    Trophy Points:
    18
    cPanel Access Level:
    Root Administrator
    Well - other websites on the same sever aren't experience that problem
     
  10. Jcats

    Jcats Well-Known Member

    Joined:
    May 25, 2011
    Messages:
    275
    Likes Received:
    31
    Trophy Points:
    28
    Location:
    New Jersey
    cPanel Access Level:
    DataCenter Provider
    Well if its a .htaccess rule than it wouldn't affect the others sites so it makes sense this could be the problem.
     
  11. InteractM

    InteractM Well-Known Member

    Joined:
    Apr 2, 2013
    Messages:
    133
    Likes Received:
    1
    Trophy Points:
    18
    cPanel Access Level:
    Root Administrator
    .htaccess has a lot of rewrite rules for redirects (about 2.5k) as well some modifications from WP plugins.
     
  12. Jcats

    Jcats Well-Known Member

    Joined:
    May 25, 2011
    Messages:
    275
    Likes Received:
    31
    Trophy Points:
    28
    Location:
    New Jersey
    cPanel Access Level:
    DataCenter Provider
    Well depending on how often the bots are hitting the site and throwing a 500 you can rename the .htaccess to something else so it stops triggering then wait for the next bot to stop by to see if it throws a 500. Otherwise, you can log into Google webmaster and you should be able to force Google to crawl the site which you can use to test it quicker so the site isn't sitting broken if it heavily relies on the .htaccess
     
  13. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    653
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    Have you been able to confirm if the "500" error messages are still occurring since increasing the output_buffering value in the php.ini file?

    Thank you.
     
  14. InteractM

    InteractM Well-Known Member

    Joined:
    Apr 2, 2013
    Messages:
    133
    Likes Received:
    1
    Trophy Points:
    18
    cPanel Access Level:
    Root Administrator
    Yes - I still have those 500's even increasing output_buffering. Also I'm not able to stack trace most of those requests with 500's neither to PHP or MySQL errors logs as well Apache error logs.

    Example of 500's from Apache access log:

    Code:
    41.79.186.247--[06/Oct/2015:11:23:49-0400]"GET /international-chamber-of-commerce-icc-ud-754/ HTTP/1.1"500-"http://www.bing.com""Mozilla/5.0 (Windows NT 6.2; rv:42.0) Gecko/20100101 Firefox/42.0"
    54.193.63.98--[06/Oct/2015:11:29:05-0400]"GET / HTTP/1.1"500-"-""webmon-webagent v1.3"
    199.167.17.37--[06/Oct/2015:11:39:23-0400]"GET / HTTP/1.1"500-"-""Mozilla/5.0 (Anturis Agent)"
    
    and appear that is relate only to one hosting account (one site) which runs Wordpress

    Another thing what I have done it was execute that code in the console:

    Code:
    export USE_ZEND_ALLOC=0
    
    what have reduced 500's from around 100 per day to something below 20. Also I have noticed that those 500's are showing up after Apache auto restart (no clue why).
     
    #14 InteractM, Oct 6, 2015
    Last edited: Oct 6, 2015
  15. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    653
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
Loading...

Share This Page