30.07.2012 Views

Reference Guide

Reference Guide

Reference Guide

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

High Memory Usage<br />

Zend Server Best Practices<br />

Description: When a specific PHP request consumes more than the specified amount of memory it<br />

generates an event. The “High Memory Usage” Rules contain the memory consumption setting (i.e. the<br />

amount of memory the request has to consume to trigger an event).<br />

Information Collected:<br />

The number of occurrences is the best indicator. A single occurrence can be disregarded (change the<br />

Status of the Issue to Closed) only if it occurs multiple times it is worth investigating. Closed events that<br />

continue to receive new activity open automatically.<br />

Applicable Diagnostic Actions:<br />

Click on a link to see how to perform each action tools are listed in order of relevance to helping solve the<br />

event:<br />

Use URL Tracing to collect further information about memory consumption.<br />

Open code in editor to see if the script can be improved<br />

View information in the Logs<br />

Possible Causes and Solutions:<br />

Database Functions - Some queries may return large record sets and should be refined.<br />

Iterative functions – functions that include many ‘foreach’ loops may cause excessive memory<br />

usage and should be reviewed to see if less memory can be consumed.<br />

False Positives - Sometimes requests consume large amounts of memory. Not all requests that<br />

consume lots of memory are indicative of a problem in your code or environment and they may<br />

be no indication of unacceptable behavior. If this is the case, set issues triggered by this function<br />

to ignored.<br />

427

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!