Apache-ASP

 view release on metacpan or  search on metacpan

site/tuning.html  view on Meta::CPAN


		</tr>
		
		<tr>
		<td bgcolor=white><font size=-2 face="verdana" color=#993399><b><nobr>&nbsp;</nobr></b></font></td>

		<td bgcolor=white ><font face="verdana,helvetica" size=-1><b><nobr><a href="changes.html" style="text-decoration:none"><font color=#063678>CHANGES</font></a></nobr></b></font></td>		

		</tr>
		
		<tr>
		<td bgcolor=white><font size=-2 face="verdana" color=#993399><b><nobr>&nbsp;</nobr></b></font></td>

		<td bgcolor=white ><font face="verdana,helvetica" size=-1><b><nobr><a href="license.html" style="text-decoration:none"><font color=#063678>LICENSE</font></a></nobr></b></font></td>		

		</tr>
		<tr><td colspan=2><hr size=1></td></tr>
		<tr>
		<td bgcolor=white><font size=-2 face="verdana" color=#993399><b><nobr>&nbsp;</nobr></b></font></td>

		<td bgcolor=white ><font face="verdana,helvetica" size=-1><b><nobr><a href="eg/index.html" style="text-decoration:none"><font color=#063678>EXAMPLES</font></a></nobr></b></font></td>		

		</tr>
		
	</table>

	</td></tr>
	</table>

		<br>
		<center>
		<a href=http://www.apache-asp.org/><img src="powered_by_apache_asp.jpg" width="88" height="31" alt="Powered by Apache::ASP" border="0"></a>
		<br>
		<a href=http://perl.apache.org><img src="powered_by_modperl.gif" width="88" height="31" alt="Powered by ModPerl and Apache" border="0"></a>
		<br>
		<a href=http://www.perl.com><img src="rectangle_power_perl.gif" width="88" height="31" alt="Powered by Perl" border="0"></a>


</center>

</td>



<td valign=top bgcolor=white>
<font size=+0 face=verdana,arial>

<font face=verdana><font class=title size=+1 color=#555555><b>TUNING</b></font>
<font face="courier new" size=3><pre>
</pre></font>A little tuning can go a long way, and can make the difference between
a web site that gets by, and a site that screams with speed.  With
Apache::ASP, you can easily take a poorly tuned site running at
10 hits/second to 50+ hits/second just with the right configuration.
<font face="courier new" size=3><pre>
</pre></font>Documented below are some simple things you can do to make the 
most of your site.</font>

	<hr size=1>
	<table width=100% border=0 cellpadding=1 cellspacing=3>
	<tr>
	<td valign=top><font face="lucida console" size=-1>
	
		<tr>
		
			<td valign=top >
			<font face="lucida console" size=-1>
			<a href=#Online%20Resou44921f06>Online Resources</a>
			</font>
			</td>
		
			<td valign=top >
			<font face="lucida console" size=-1>
			<a href=#Precompile%20Sfb36ef6e>Precompile Scripts</a>
			</font>
			</td>
							
		</tr>
		
		<tr>
		
			<td valign=top >
			<font face="lucida console" size=-1>
			<a href=#Tuning%20%26%20Ben0cdacf8c>Tuning & Benchmarking</a>
			</font>
			</td>
		
			<td valign=top >
			<font face="lucida console" size=-1>
			<a href=#No%20.htaccessc4c9e884>No .htaccess or StatINC</a>
			</font>
			</td>
							
		</tr>
		
		<tr>
		
			<td valign=top >
			<font face="lucida console" size=-1>
			<a href=#%24Application941f90bf>$Application & $Session State</a>
			</font>
			</td>
		
			<td valign=top >
			<font face="lucida console" size=-1>
			<a href=#Turn%20off%20Debe0bab100>Turn off Debugging</a>
			</font>
			</td>
							
		</tr>
		
		<tr>
		
			<td valign=top >
			<font face="lucida console" size=-1>
			<a href=#Low%20MaxClien5a8237ea>Low MaxClients</a>
			</font>
			</td>
		
			<td valign=top >
			<font face="lucida console" size=-1>
			<a href=#Memory%20Sparia73a9626>Memory Sparing, NoCache</a>
			</font>
			</td>
							
		</tr>
		
		<tr>
		
			<td valign=top >
			<font face="lucida console" size=-1>
			<a href=#High%20MaxRequ0724a06d>High MaxRequestsPerChild</a>
			</font>
			</td>
		
			<td valign=top >
			<font face="lucida console" size=-1>
			<a href=#Resource%20Limfd66f2d8>Resource Limits</a>
			</font>
			</td>
							
		</tr>
		
		<tr>
		
			<td valign=top >
			<font face="lucida console" size=-1>
			<a href=#Precompile%20M39676a96>Precompile Modules</a>
			</font>
			</td>
		<td>&nbsp;</td>					
		</tr>
			
	</table>
	<hr size=1>
	<p>

	<p>
	<a name=Online%20Resou44921f06></a>
	<font face=verdana><font class=title size=+0 color=#555555><b>Online Resources</b></font>
<font face="courier new" size=3><pre>
</pre></font>For more tips &amp; tricks on tuning Apache and <a href=http://perl.apache.org><font size=-1 face=verdana><b>mod_perl</b></font></a>, please see the tuning
documents at:
<font face="courier new" size=3><pre>
  <a href="http://perl.apache.org/guide/">Stas Bekman&#39;s mod_perl guide</a>
</pre></font>Written in late 1999 this article provides an early look at 
how to tune your Apache::ASP web site.  It has since been
updated to remain current with Apache::ASP v2.29+
<font face="courier new" size=3><pre>
  <a href="http://www.apache-asp.org/articles/perlmonth3_tune.html">Apache::ASP Site Tuning</a>
</pre></font>
	
	<p>
	<a name=Tuning%20%26%20Ben0cdacf8c></a>
	<font face=verdana><font class=title size=+0 color=#555555><b>Tuning & Benchmarking</b></font>
<font face="courier new" size=3><pre>
</pre></font>When performance tuning, it is important to have a tool to
measure the impact of your tuning change by change.
The program ab, or Apache Bench, provides this functionality
well, and is freely included in the apache distribution.
<font face="courier new" size=3><pre>
</pre></font>Because performance tuning can be a neverending affair,
it is a good idea to establish a threshold where performance
is &quot;good enough&quot;, that once reached, tuning stops.</font>
	
	<p>
	<a name=%24Application941f90bf></a>
	<font face=verdana><font class=title size=+0 color=#555555><b>$Application & $Session State</b></font>
<font face="courier new" size=3><pre>
</pre></font>Use NoState 1 setting if you don&#39;t need the $Application or $Session
objects. State objects such as these tie to files on disk and will incur a
performance penalty.
<font face="courier new" size=3><pre>
</pre></font>If you need the state objects $Application and $Session, and if 
running an OS that caches files in memory, set your &quot;StateDir&quot; 
directory to a cached file system.  On WinNT, all files 
may be cached, and you have no control of this.  On Solaris, /tmp is
a RAM disk and would be a good place to set the &quot;StateDir&quot; config 
setting to.  When cached file systems are used there is little 
performance penalty for using state files.  Linux tends to do a good job 
caching its file systems, so pick a StateDir for ease of system 
administration.
<font face="courier new" size=3><pre>
</pre></font>On Win32 systems, where <a href=http://perl.apache.org><font size=-1 face=verdana><b>mod_perl</b></font></a> requests are serialized, you 
can freely use SessionSerialize to make your $Session requests
faster, and you can achieve similar performance benefits for
$Application if you call $Application-&gt;Lock() in your 



( run in 2.003 seconds using v1.01-cache-2.11-cpan-39bf76dae61 )