<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>apache 2 &#8211; lifeLinux: Linux Tips, Hacks, Tutorials, Ebooks</title>
	<atom:link href="http://lifelinux.com/tag/apache-2/feed/" rel="self" type="application/rss+xml" />
	<link>http://lifelinux.com</link>
	<description>All About Linux !</description>
	<lastBuildDate>Sun, 28 Aug 2011 09:56:12 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=5.5.18</generator>
	<item>
		<title>Installing Apache With Worker MPM And PHP-FastCGI</title>
		<link>http://lifelinux.com/installing-apache-with-worker-mpm-and-php-fastcgi/</link>
					<comments>http://lifelinux.com/installing-apache-with-worker-mpm-and-php-fastcgi/#comments</comments>
		
		<dc:creator><![CDATA[lifeLinux]]></dc:creator>
		<pubDate>Sun, 28 Aug 2011 09:01:34 +0000</pubDate>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[WebServer]]></category>
		<category><![CDATA[/usr/local/etc/apache22/httpd.conf]]></category>
		<category><![CDATA[apache 2]]></category>
		<category><![CDATA[binary compatibility]]></category>
		<category><![CDATA[fastcgi]]></category>
		<category><![CDATA[fcgi]]></category>
		<category><![CDATA[freebsd php apache]]></category>
		<category><![CDATA[freebsd php fastcgi]]></category>
		<category><![CDATA[freebsd php5 fastcgi]]></category>
		<category><![CDATA[httpd]]></category>
		<category><![CDATA[mod fcgi]]></category>
		<category><![CDATA[php5]]></category>
		<category><![CDATA[ports]]></category>
		<category><![CDATA[process management]]></category>
		<category><![CDATA[suhosin]]></category>
		<category><![CDATA[zend engine]]></category>
		<category><![CDATA[zend technologies]]></category>
		<guid isPermaLink="false">http://www.lifelinux.com/?p=1138</guid>

					<description><![CDATA[<p>The worker MPM uses multiple child processes with many threads each. Each thread handles one connection at a time. Worker generally is a good choice for high-traffic servers because it has a smaller memory footprint than the prefork MPM. This guide provides the process of switching from Apache&#8217;s default installation of MPM Prefork to that [&#8230;]</p>
<p>The post <a rel="nofollow" href="http://lifelinux.com/installing-apache-with-worker-mpm-and-php-fastcgi/">Installing Apache With Worker MPM And PHP-FastCGI</a> appeared first on <a rel="nofollow" href="http://lifelinux.com">lifeLinux: Linux Tips, Hacks, Tutorials, Ebooks</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p></p><p>The worker MPM uses multiple child processes with many threads each. Each thread handles one connection at a time. Worker generally is a good choice for high-traffic servers because it has a smaller memory footprint than the prefork MPM. This guide provides the process of switching from Apache&#8217;s default installation of MPM Prefork to that of MPM Worker and i will also be covering the proper installation of FastCGI (mod_fcgid) to further improve your server performance.<br />
<span id="more-1138"></span></p>
<h2>Install Apache &amp; Switching Apache to Worker MPM mode</h2>
<p>To install apache on CentOS, type the following command as root</p>
<pre># yum install httpd</pre>
<p>If you want to run Apache by default when the system boots, type the following command</p>
<pre># chkconfig httpd --level 2345 on</pre>
<p>To start Apache for the first time, type the following command</p>
<pre># /etc/init.d/httpd start</pre>
<p>To switch Apache to Worker MPM mode edit /etc/sysconfig/httpd</p>
<pre># vi /etc/sysconfig/httpd</pre>
<p>Uncomment the following line</p>
<pre>HTTPD=/usr/sbin/httpd.worker</pre>
<h2>Install PHP &amp; mod_fcgid</h2>
<p>To install PHP 5.3 on CentOS, type the following command</p>
<pre># yum install php53</pre>
<p>Apache run mod_php by default, to disable mod_php, type the following command</p>
<pre># mv /etc/httpd/conf.d/php.conf /etc/httpd/conf.d/php.conf.bak</pre>
<p>To install mod_fcgid, the first you need to ensure httpd-devel package installed, enter</p>
<pre># yum install httpd-devel</pre>
<p>Download &amp; Extract mod_fcgid</p>
<pre># wget http://www.apache.org/dist/httpd/mod_fcgid/mod_fcgid-2.3.6.tar.gz
tar zxvf mod_fcgid-2.3.6.tar.gz
cd mod_fcgid-2.3.6</pre>
<p>To compile mod_fcgid, type the following command</p>
<pre># ./configure.apxs
# make
# make install</pre>
<p>The module will be automatically installed and specified in the configuration file of the Apache. The next step create config for mod_fcgi, enter</p>
<pre># vi /etc/httpd/conf.d/mod_fcgid.conf</pre>
<p>Add the following content</p>
<pre>AddHandler php-fcgi
&lt;FilesMatch \.php$&gt;
Options +ExecCGI
AddHandler php-fcgi .php
FCGIWrapper /var/www/cgi-bin/php-fcgi .php
&lt;/FilesMatch&gt;
AddType text/html .php
DirectoryIndex index.php</pre>
<p>Create php-fcgi script in cgi-bin, enter</p>
<pre>
# vi /var/www/cgi-bin/php-fcgi
</pre>
<p>Add the following content</p>
<pre>
#!/bin/sh
PHPRC=/etc/
export PHPRC
export PHP_FCGI_MAX_REQUESTS=5000
export PHP_FCGI_CHILDREN=0
exec /usr/bin/php-cgi
</pre>
<p>Make file executable</p>
<pre>
# chmod +x /var/www/cgi-bin/php-fcgi
</pre>
<p>I would recommend that you specify the line below in /etc/php.ini cgi.fix_pathinfo = 1, enter</p>
<pre>
# echo "cgi.fix_pathinfo = 1" >> /etc/php.ini
</pre>
<p>Final, restart Apache with the following command</p>
<pre>
# /etc/init.d/httpd restart
</pre>
<g:plusone href="http://lifelinux.com/installing-apache-with-worker-mpm-and-php-fastcgi/" size="standard"  annotation="none"   ></g:plusone><p>The post <a rel="nofollow" href="http://lifelinux.com/installing-apache-with-worker-mpm-and-php-fastcgi/">Installing Apache With Worker MPM And PHP-FastCGI</a> appeared first on <a rel="nofollow" href="http://lifelinux.com">lifeLinux: Linux Tips, Hacks, Tutorials, Ebooks</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>http://lifelinux.com/installing-apache-with-worker-mpm-and-php-fastcgi/feed/</wfw:commentRss>
			<slash:comments>3</slash:comments>
		
		
			</item>
		<item>
		<title>How To Limit File Upload Size On Apache</title>
		<link>http://lifelinux.com/how-to-limit-file-upload-size-on-apache/</link>
					<comments>http://lifelinux.com/how-to-limit-file-upload-size-on-apache/#respond</comments>
		
		<dc:creator><![CDATA[lifeLinux]]></dc:creator>
		<pubDate>Tue, 24 May 2011 09:25:56 +0000</pubDate>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Sys Admin]]></category>
		<category><![CDATA[WebServer]]></category>
		<category><![CDATA[apache .htaccess]]></category>
		<category><![CDATA[apache 2]]></category>
		<category><![CDATA[configuration options]]></category>
		<category><![CDATA[htaccess]]></category>
		<category><![CDATA[Limiting Upload Size]]></category>
		<category><![CDATA[LimitRequestBody]]></category>
		<category><![CDATA[request body]]></category>
		<category><![CDATA[restart apache web server]]></category>
		<category><![CDATA[uploads]]></category>
		<category><![CDATA[virtual host]]></category>
		<guid isPermaLink="false">http://www.lifelinux.com/?p=748</guid>

					<description><![CDATA[<p>To limit the total size of the HTTP request body sent from the client use LimitRequestBody Directive. The LimitRequestBody directive allows the user to set a limit on the allowed size of an HTTP request message body within the context in which the directive is given (server, per-directory, per-file or per-location). If the client request [&#8230;]</p>
<p>The post <a rel="nofollow" href="http://lifelinux.com/how-to-limit-file-upload-size-on-apache/">How To Limit File Upload Size On Apache</a> appeared first on <a rel="nofollow" href="http://lifelinux.com">lifeLinux: Linux Tips, Hacks, Tutorials, Ebooks</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p></p><p>To limit the total size of the HTTP request body sent from the client use <strong>LimitRequestBody</strong> Directive.<br />
<span id="more-748"></span><br />
The <strong>LimitRequestBody</strong> directive allows the user to set a limit on the allowed size of an HTTP request message body within the context in which the directive is given (server, per-directory, per-file or per-location). If the client request exceeds that limit, the server will return an error response instead of servicing the request. The size of a normal request message body will vary greatly depending on the nature of the resource and the methods allowed on that resource. CGI scripts typically use the message body for passing form information to the server. Implementations of the PUT method will require a value at least as large as any representation that the server wishes to accept for that resource.</p>
<p>This directive gives the server administrator greater control over abnormal client request behavior, which may be useful for avoiding some forms of denial-of-service attacks.</p>
<p>This directive specifies the number of bytes from 0 (meaning unlimited) to 2147483647 (2GB) that are allowed in a request body.</p>
<p>For example,if we want to limit upload size to 100k for  /var/www/html/uploads, we need to add below commands to .htaccess or httpd.conf.</p>
<pre>
&lt;Directory "/var/www/html/uploads"&gt;
    LimitRequestBody 102400
&lt;/Directory&gt;
</pre>
<p>Finally, restart apache ( if added to httpd.conf ), type the following command as root</p>
<pre>
# /etc/init.d/httpd graceful
</pre>
<g:plusone href="http://lifelinux.com/how-to-limit-file-upload-size-on-apache/" size="standard"  annotation="none"   ></g:plusone><p>The post <a rel="nofollow" href="http://lifelinux.com/how-to-limit-file-upload-size-on-apache/">How To Limit File Upload Size On Apache</a> appeared first on <a rel="nofollow" href="http://lifelinux.com">lifeLinux: Linux Tips, Hacks, Tutorials, Ebooks</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>http://lifelinux.com/how-to-limit-file-upload-size-on-apache/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
